Solved

Saving & Loading a TStringGrid

Posted on 1997-11-25
1
225 Views
Last Modified: 2010-04-04
How do I do a "SaveToFile" and "LoadFromFile" (or equivalent) of a TStringGrid??
I am using D1.
0
Comment
Question by:jdthedj
1 Comment
 
LVL 2

Accepted Solution

by:
Waldek earned 50 total points
ID: 1351910
You must create a descendant of TSringGrid with two additional method SaveToFile and LoadFromFIle. To create Savetofile you must save to textfile fist RowCount and colCount. After this You must save all cells with for i:=0 to col-1
                     for j:=0 to rows-1
                      writeln(f,cells[j,i]);
To load from file You must load first a cols and rows , then You must load data to every cell

0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question