label with address format

J

JohnE

I have a label in a formview and when it fills with data from the db it
should be in the format of an address. As in;

Name
address
city, state, zipcode
phone

You can see what I am getting at. Currently the info goes in and just
wraps. How do I go about getting the proper format? Would it be better to
use a textbox for this? How would the address structure be done for txtbox?

Thanks
John
 
M

Mr. Arnold

JohnE said:
I have a label in a formview and when it fills with data from the db it
should be in the format of an address. As in;

Name
address
city, state, zipcode
phone

You can see what I am getting at. Currently the info goes in and just
wraps. How do I go about getting the proper format? Would it be better to
use a textbox for this? How would the address structure be done for txtbox?

Thanks
John

You can use a multiple line textbox I think. You would use a string
variable and take each piece of information above, concatenate it into
the string variable. You would at the end of each word concatenated into
the string variable, you can concatenate a CRLF (Carriage Return Line
Feed) at the end of the word so that it does a CRLF in the multiline
textbox after each line of words. It should work, when you take the
string varable and set the Textbox.Text with it.

You can disable the Keypress Event for the HTML textbox so that the user
cannot enter data in the textbox or set the textbox Enable/Disable
property to 'Disable' after the textbox has been loaded.

You can do that or use a Listbox control loading each line of string
data into the Listbox collection, ignoring any line selection by the
user in the Listbox.

Myself, I would look into the Listbox control.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top