Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Weird problem!

In Access, and most other application, a line feed is actually represented
as two characters: carriage return (code 13) + line feed (code 10). In
Excel, however, a line feed within a cell is represented as only the single
line feed character (code 10). The carriage return shows up as a box or
vertical bar. Looks like the line feed also is not interpreted correctly
when preceded by the carriage return until after you edit the cell.

You could write a macro to simply replace all instances of CR + LF with just
a LF. For example:

text = Cells(row,col).Value
Cells(row, col).Value = Replace(text, Chr(13) + Chr(10), Chr(10))


"Dan" wrote in message
...
Hi!

I have a problem that I hope someone will be able to help me with. I have

an Access table that I exported to Excel. Some of the data has linfeeds in
them, separating small paragraphs. For some reason, it displays these
linefeeds as single heavy vertical bars. I tried it another way and it
displays linefeeds as square boxes. The funny thing is, it displays the
linefeed correctly in the address bar. Then, when I click anywhere in the
address bar of one of those suspect cells and then press enter, it displays
the linefeed correctly in the cell. Any ideas???

Any help would be greatly appreciated.

Thanks a lot!

Dan



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
weird problem WarrenK Setting up and Configuration of Excel 0 June 5th 09 05:46 PM
Weird Problem Gaurav[_2_] Excel Worksheet Functions 4 December 17th 07 04:27 PM
Weird problem Sue Excel Worksheet Functions 2 November 29th 05 12:10 PM
Weird Problem Patrick Excel Worksheet Functions 4 March 28th 05 02:29 AM
Weird VBA problem Bob[_55_] Excel Programming 3 May 12th 04 11:39 PM


All times are GMT +1. The time now is 03:14 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"