By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,593 Members | 2,006 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,593 IT Pros & Developers. It's quick & easy.

Print multiple data fields (pre-formated) into a text box

P: 1
I am trying to make a database application. Users will input data into a number of fields(saved to an access database) and then click a button to populate a text box with all the data entered in a predetermined format. I.E.:

User types in name, street address, city, state, and zip into five different boxes.
They could then hit a button and a sixth box would take the data and display it like

name
street address
city, state zip

It would format it on multiple lines and add commas or other characters in between the sets of data.

Any hints or directions to information on doing this would be appreciated.

Chris
(I am using VB 2005)
Nov 5 '06 #1
Share this Question
Share on Google+
2 Replies


100+
P: 267
I am trying to make a database application. Users will input data into a number of fields(saved to an access database) and then click a button to populate a text box with all the data entered in a predetermined format. I.E.:

User types in name, street address, city, state, and zip into five different boxes.
They could then hit a button and a sixth box would take the data and display it like

name
street address
city, state zip

It would format it on multiple lines and add commas or other characters in between the sets of data.

Any hints or directions to information on doing this would be appreciated.

Chris
(I am using VB 2005)
hi
make your new textbox 'multiline' and use something like:
text1.text = Name & vbCrLf & Street & vbCrLf & City & ", " & State & " " & Zip
Nov 5 '06 #2

Expert 5K+
P: 8,434
hi
make your new textbox 'multiline' and use something like:
text1.text = Name & vbCrLf & Street & vbCrLf & City & ", " & State & " " & Zip
You might also consider using the vbNewline constant rather than vbCrLf. Same value, I believe, but a more "readable" name.
Nov 5 '06 #3

Post your reply

Sign in to post your reply or Sign up for a free account.