I know that for numbers, you can DataFormat objects with # or 0 depending on whether you want 0s to show in that object. Is there a same thing for characters and whether or not you are showing spaces/blanks?
My problem is that RPG3 will blank out fields with spaces when stored on the AS400, but then I use VB to pull it onto a PC and show it in objects (textboxes, labels, etc) and those spaces are there. So if you click anywhere in a text box, the cursor will show where you clicked, not at the beginning of the text box.
Is there a function check, compare statement or DataFormat that I can use to get rid of those blanks? The best I have come up with is:
If txtTest.Text = " " Then
txtTest.Text = ""
End If
The " " is however many spaces the field in RPG3 is, since you have to define field lengths.
My problem is that RPG3 will blank out fields with spaces when stored on the AS400, but then I use VB to pull it onto a PC and show it in objects (textboxes, labels, etc) and those spaces are there. So if you click anywhere in a text box, the cursor will show where you clicked, not at the beginning of the text box.
Is there a function check, compare statement or DataFormat that I can use to get rid of those blanks? The best I have come up with is:
If txtTest.Text = " " Then
txtTest.Text = ""
End If
The " " is however many spaces the field in RPG3 is, since you have to define field lengths.