Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

add chr(13) to a report textbox? 3

Status
Not open for further replies.

thatguy

Programmer
Aug 1, 2001
283
US
I'm trying to put two text fields in a report, one right above the other (or one right below the other, depending on how you're holding the page).

The prob comes in with this: the upper field Can Grow, so I would like to combine the two fields into one textbox with a chr(13) (so the upper textbox doesn't overwrite the bottom one, of course). I set the controlsource to this:

=([PartDesc] & chr(13) & [PartNotes])

But that just puts a little square in where the carriage return should be. Any suggestions?

Thanks
-- michael~
 
nope... that just treats the vbCrLf like a parameter..
 
=[PartDesc] & "
" & [PartNotes]

...quote then ctrl+enter then endquote...
 
In the On Format event of the section where the text box is, put code like this:
Code:
Me.txtPartInfo = [PartDesc] & vbCrLf & [PartNotes]
 
You can do what CosmoKramer suggests but it must be in the code page not on the Property page:

In Format_Detail()

Me.YourControlName =[PartDesc] & vbCrLf & [PartNotes]

 
WooHoo!! It works! Thank you so much!

-- michael~
 
ohhhhh... i see.. I'm not familiar with the Code part of reports.. I'll have to look into that.. thanks!

-- michael~
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top