Hi all, I want navision to not cut off blanks entered at the end of a textfield. Is this possible? Thanks in advance!
Hi Alex, you can use Text := DELCHR(Text,’>’,’ ') to cut off trailing blanks, where text is your textfield. Michael
Hi, Directly it is not possible. You have to do little bit coding.
@Michael: Thanks, but you got me wrong. I don’t want to cut off the blanks at the end, I want to keep trailing blanks entered in a text field. @Rajesh: Sounds interesting… how do I do it?
Hi Alex, sorry, the opposite command is: Text := PADSTR(text,n,’ '); where n = length of the textstring and the filed is concatenated up to the length of n. But now it depends upon your intention: do you want to add a fixed number of blanks, so you have to find out the length of the text entered and perhaps the maximum length defined. So write more details. Michael
If a user types "some text " into a textfield, only “some text” will be saved to the database. In a certain table this is not what I want. After my vacation I found a solution, and it’s so easy I’m a bit ashamed: ------------------------------------------------------------------------ OnAfterInput(VAR Text : Text[260] length := strlen(text); OnAfterValidate() “Fieldname” := padstr(“Fieldname”,length,’ '); ------------------------------------------------------------------------ Thank you all, Alex