Home
Top.Mail.Ru Yandeks.Metrika
Forum: "Main";
Current archive: 2002.01.08;
Download: [xml.tar.bz2];

Down

Help with two questions! Find similar branches


Socol   (2001-12-15 10:45) [0]

Hello dear gopoda programmers!
Help write variables to a file and load them.
There are 3 Labels
And 3 Variables ABC
The task is to write variables to files and load them if necessary.
You need to assign labels to labels like this
Label1.caption: = A;
Label2.caption: = B;
Label3.caption: = C;
and then, when you click on a commandbuton, the variables are saved in peremen.sav.
And similarly loaded.
+++ How to download anemia image * .gif +++
I thank everyone who answered!



Anatoly Podgoretsky   (2001-12-15 11:43) [1]

Readln (f, a, b, c);
Writeln (f, a, b, c);



Song   (2001-12-15 22:22) [2]

Type Rec = Record
a, b, c: String;
End;
Var ff: File of Rec;
n: Rec;

.

Read (ff, n);

Label1.Caption: = na;
Label1.Caption: = nb;
Label1.Caption: = nc;

.

Write (ff, n);


It's simple !!!



Вадим   (2001-12-15 23:05) [3]

2Song

Type Rec = Record
a, b, c: String;
End;
Var ff: File of Rec;
n: Rec;

This will not work, you need to use ShortString;



Song   (2001-12-16 22:28) [4]

Yes, I just forgot, but I do this: a, b, c: String [100];
this will work



KilkennyCat   (2001-12-17 03:48) [5]

It will not work in any way :)
you forgot to open the file :))



Builder   (2001-12-17 03:53) [6]

Or maybe writeComponent? :)



Song   (2001-12-19 23:24) [7]

Well, it’s as clear as daylight that you need to open it, reset it for reading, and then close it - you just didn’t write any extra info, everyone knows that already! (look at the crux of the matter)



Pages: 1 whole branch

Forum: "Main";
Current archive: 2002.01.08;
Download: [xml.tar.bz2];

Top









Memory: 0.57 MB
Time: 0.024 c
1-22123
dimonf
2001-12-15 16:33
2002.01.08
Question about


6-22308
Igor
2001-10-14 09:44
2002.01.08
Data exchange between client and server in Delphi


1-22133
Sand worm
2001-12-19 14:55
2002.01.08
Frame


4-22503
Yura
2001-11-05 20:11
2002.01.08
Enter a string in the window


14-22369
Victor Tsay
2001-11-08 09:11
2002.01.08
How in the Delphi editor to shift blocks of text?





afrikaans albanian Arabic armenian azerbaijani basque belarusian bulgarian catalan Chinese (Simplified) Chinese (Traditional) croatian Czech danish Dutch English estonian filipino finnish French
galician georgian German greek haitian Creole hebrew Hindi hungarian icelandic indonesian Irish italian Japanese Korean latvian lithuanian macedonian malay maltese norwegian
persian polish portuguese Romanian russian serbian slovak Slovenian Español swahili Swedish thai turkish Ukrainian urdu vietnamese welsh yiddish bengali bosnian
cebuano Esperanto gujarati hausa hmong igbo javanese kannada khmer lao latin maori marathi mongolian nepali punjabi somali tamil telugu yoruba
zulu
English French German Italian Portuguese Russian Spanish