Paurths
asked on
Export to Excel: vbCrlf
Hi,
whenever i export data from, for example a textbox with multiline enabled, to MS Excel, it will show me squares in the excel sheet for each vbCrlf there was in the textbox.
Here's an example of the code:
*********
xlSht.Cells(3, 1).Value = txtRoot(1).Text
*********
Assuming the txtRoot(1) has this data in it:
26578
3246
3444
Then it wil show a square after each number once it is inside a cell in Excel.
How to trap this? (and replace by ALT + ENTER ?)
cheers
Ricky
whenever i export data from, for example a textbox with multiline enabled, to MS Excel, it will show me squares in the excel sheet for each vbCrlf there was in the textbox.
Here's an example of the code:
*********
xlSht.Cells(3, 1).Value = txtRoot(1).Text
*********
Assuming the txtRoot(1) has this data in it:
26578
3246
3444
Then it wil show a square after each number once it is inside a cell in Excel.
How to trap this? (and replace by ALT + ENTER ?)
cheers
Ricky
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
It chokes on a carriage return, so the trick is to just use a line feed.
ASKER
Thanks Paul,
seeing it i am somewhat ashamed lol,
i can't believe i looked over vbLf...
thanks again,
cheers
Ricky
seeing it i am somewhat ashamed lol,
i can't believe i looked over vbLf...
thanks again,
cheers
Ricky