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.56 MB
Time: 0.025 c
3:21978
Anonymous worker
2001-12-04 20:25
2002.01.08
ADO + Excel + Delphi5


4:22465
AKV
2001-11-02 10:44
2002.01.08
how to determine the window handle over which the mouse is located


14:22395
Alien
2001-11-07 01:15
2002.01.08
What mess is different from the order?


3:21920
Alex2
2001-12-04 15:14
2002.01.08
Error at completion


6:22298
karafuto
2001-10-11 14:00
2002.01.08
Why do you need TIdAntiFreeze (InDy)?





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 Spanish 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