ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   embed <alt<enter for multiline cell in a CSV file (https://www.excelbanter.com/excel-programming/279455-embed-alt-enter-multiline-cell-csv-file.html)

John Lopez

embed <alt<enter for multiline cell in a CSV file
 
Hi,

I have a database program (MatrixOne, with Oracle as
middleware) that parses data returned from a query, then
writes a CSV file, and finally launches it with Excel for
the users view.

I know there are better ways, but this is what we have
right now.

I need to embed an <alt<enter in the cell contents as a
new line delimeter, so as to create multiline cell data.

I have attempted to write an octal \034 between the data
pieces, but it does not really do what I need, just
creates a nonprinting character in the string, which
remains linear.

Thanks for your help.

Tom Ogilvy

embed <alt<enter for multiline cell in a CSV file
 
alt+enter produces Char(10). If you were doing it with a formula

="ABCD" & char(10) & "CDEF"

in VBA
Range("A1").Value = "ABCD" & chr(10) & "EFGH"

The cell needs to have wordwrap set for it to actually wrap.

--
Regards,
Tom Ogilvy

John Lopez wrote in message
...
Hi,

I have a database program (MatrixOne, with Oracle as
middleware) that parses data returned from a query, then
writes a CSV file, and finally launches it with Excel for
the users view.

I know there are better ways, but this is what we have
right now.

I need to embed an <alt<enter in the cell contents as a
new line delimeter, so as to create multiline cell data.

I have attempted to write an octal \034 between the data
pieces, but it does not really do what I need, just
creates a nonprinting character in the string, which
remains linear.

Thanks for your help.




John Lopez

embed <alt<enter for multiline cell in a CSV file
 
Thanks for your help.

I am actually writing this in TCL/TK which is the native development
language for the Matrix/Oracle database.


Therefore, unlike MSVB, TCL does not have a string construct that will
allow something like "char(10)".

I did do a different test last night and found that by doing:

regsub -all -- ":" [mql print bus $xID select state.name dump ":";]
"\034" y1

When viewed in Excel, the octal 034 appears as a non-printing char.
However, it does not wrap as desired.

Thanks


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Tom Ogilvy

embed <alt<enter for multiline cell in a CSV file
 
Character 10 would be

\012 in octal (if I understand your notation).

--
Regards


"John Lopez" wrote in message
...
Thanks for your help.

I am actually writing this in TCL/TK which is the native development
language for the Matrix/Oracle database.


Therefore, unlike MSVB, TCL does not have a string construct that will
allow something like "char(10)".

I did do a different test last night and found that by doing:

regsub -all -- ":" [mql print bus $xID select state.name dump ":";]
"\034" y1

When viewed in Excel, the octal 034 appears as a non-printing char.
However, it does not wrap as desired.

Thanks


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!





All times are GMT +1. The time now is 04:49 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com