Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Textbox controlsource
Message
From
28/09/2003 21:43:43
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
28/09/2003 21:40:34
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00833044
Message ID:
00833047
Views:
27
>>i have "employee.lastname" in my textbox's controlsource property.
>>
>>how can i display the firstname and lastname in the same textbox?
>
>In a Column, you can directly set the ControlSource = [alltrim(LastName) + ", " + alltrim(FirstName)] or something similar.
>
>This doesn't work for a regular textbox; you can leave the ControlSource blank, and put the following code in TextBox.Refresh():
>
>This.Value = [alltrim(LastName) + ", " + alltrim(FirstName)]
>
>BTW, the [ and ] serve as another level of quotation marks. You could also alternate ' and " (single and double quotation marks), instead.
>
>HTH,
>
>Hilmar.

Correction: You need the outer quotation marks for the ControlSource, but not for This.Value. The second example should then be:
This.Value = alltrim(LastName) + ", " + alltrim(FirstName)
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Reply
Map
View

Click here to load this message in the networking platform