Values in Memos
Hello all,
i have got plenty memos with float values in it. I need to add these values.
ShowMessage(FloatToStr(Memo1.Value)) gives an empty Message back. XY := StrToFloat(Memo1.Text) gives an error back (xx,xx is a invalid floating point value).
How can i get the values of the Memos?
Thx 4 help.
i have got plenty memos with float values in it. I need to add these values.
ShowMessage(FloatToStr(Memo1.Value)) gives an empty Message back. XY := StrToFloat(Memo1.Text) gives an error back (xx,xx is a invalid floating point value).
How can i get the values of the Memos?
Thx 4 help.
Comments
Hi.
The 'value' property I think is only available inside the OnGetValue-event. Else you shold access the text property.
Try: ShowMessage(Memo1.text);
thanks 4 your anwser, but this didn't help.
There is no OnGetValue-event to choose on Memos, DetailData, MasterData.
In all other events (onAfterPrint, onBeforePrint, onAfterData,...) the 'value' property isn't available too.
edit:
showmessage(memo1.text) returns the correct memo-content.
edit2:
if i manually fill values in the memo, memo1.values is empty.
if the memo receives the values from DetailData or MasterData, the value property is accessable. crazy huh?
Sorry about that. I meant OnAfterData-event.
And then, the value only returns what comes from fields or variables inside the memo, not from text.
Example: '[mydb."myfield"] my text' in a memo will return the contens of mydb."myfield" as value (and ignore 'my text').