basically:
1. PROMPT-FOR only reads input into the screen buffer (and doesn't ASSIGN to record buffer)
if you want to validate input data, before assigning into record buffer, use this method:
if myValidation(input fieldname) then ASSIGN fieldname.
2. SET reads input, and does ASSIGN to record buffer
(like a combination of PROMPT-FOR and ASSIGN)
3. UPDATE displays current field value, reads input, and assigns the record buffer
(like a combination of: DISPLAY,PROMPT-FOR,ASSIGN)
experiment with this:
Code:
[LEFT][SIZE=1][FONT=LucidaSansTypewriter][SIZE=1][FONT=LucidaSansTypewriter]DEFINE VARIABLE x AS INTEGER INITIAL 3.[/FONT][/SIZE]
[SIZE=1][FONT=LucidaSansTypewriter]PROMPT-FOR x. MESSAGE "Record buffer" x SKIP(0) "Screen buffer" INPUT x.[/FONT][/SIZE]
[SIZE=1][FONT=LucidaSansTypewriter]SET x. MESSAGE "Record buffer" x SKIP(0) "Screen buffer" INPUT x.[/FONT][/SIZE]
[SIZE=1][FONT=LucidaSansTypewriter]UPDATE x. MESSAGE "Record buffer" x SKIP(0) "Screen buffer" INPUT x.[/FONT][/SIZE][/LEFT]
[/FONT][/SIZE]