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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multiline textbox

Status
Not open for further replies.

telande35

Programmer
Nov 27, 2004
24
BE
Hey,

I put a textbox on my report and will filled in with VBA code as follows

Text4.text = "GGHGHGH"

How can I put more lines in a textbox.

I tried
Text4.text = "First Line" & "\n" "Second line"


But now luck.
Nic
 
Try one of the VBA constants:

[tt]Text4.text = "First Line" & vbCrLf & "Second line"[/tt]

or vbNewline, or Chr(13) & chr(10)...

Roy-Vidar
 

You also need to set the Multiline property to true in order to get the cr/lf to wrap, rather that showing two blots.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top