Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
RWN RWN is offline
external usenet poster
 
Posts: 104
Default Double Dashes Causing problems in downloaded records

Downloaded a file that has certain fields containing leading "--" values.
Excel treats some, but not all(?) as a formula and gives a #NAME error.
I understand its interpretation of the dashes-although I've never used them-and why it
results in the error.
I am looking for a way to eliminate them and retain the text in the field.
An example is;
Dl'd value of --AGCY NOT NUMERIC XXXXXXXXX, results in;
=--AGCY NOT NUMERIC XXXXXXXXX
XL inserts the "=" sign and results in the Name error.

Strangely, it is not consistent throughout, for ex;
"--AGCY NOT NUMERIC 04041011"
is OK. The only difference being that the 1st example has "X's in the field whereas the
second has numbers(?)

At the end of the day I'd like to retain the text value following the dashes.

--
Regards;
Rob
------------------------------------------------------------------------


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Double Dashes Causing problems in downloaded records

If the double dashes only appear at the front of those "formulas", maybe just a
mass change:

Edit|replace
what: =--
with: '-- (apostrophe, dash, dash)
replace all

=======
Depending on how you're bringing them into excel (Opening a .txt file maybe).
You can specify Text as the field type in the data import wizard.



RWN wrote:

Downloaded a file that has certain fields containing leading "--" values.
Excel treats some, but not all(?) as a formula and gives a #NAME error.
I understand its interpretation of the dashes-although I've never used them-and why it
results in the error.
I am looking for a way to eliminate them and retain the text in the field.
An example is;
Dl'd value of --AGCY NOT NUMERIC XXXXXXXXX, results in;
=--AGCY NOT NUMERIC XXXXXXXXX
XL inserts the "=" sign and results in the Name error.

Strangely, it is not consistent throughout, for ex;
"--AGCY NOT NUMERIC 04041011"
is OK. The only difference being that the 1st example has "X's in the field whereas the
second has numbers(?)

At the end of the day I'd like to retain the text value following the dashes.

--
Regards;
Rob
------------------------------------------------------------------------


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.programming
RWN RWN is offline
external usenet poster
 
Posts: 104
Default Double Dashes Causing problems in downloaded records

Thanks Dave;
That worked, don't know why I didn't think of it, probably because I was too "intrigued"
by it only happening on some of the instances.
The file was the result of bringing in a "txt" file but, because I didn't expect the
situation, I left it as General. Of course I only discovered the problem after I'd sent
the XLS home (original txt file is at work)!

Anyway, all is well.

--
Regards;
Rob
------------------------------------------------------------------------
"Dave Peterson" wrote in message
...
If the double dashes only appear at the front of those "formulas", maybe just a
mass change:

Edit|replace
what: =--
with: '-- (apostrophe, dash, dash)
replace all

=======
Depending on how you're bringing them into excel (Opening a .txt file maybe).
You can specify Text as the field type in the data import wizard.



RWN wrote:

Downloaded a file that has certain fields containing leading "--" values.
Excel treats some, but not all(?) as a formula and gives a #NAME error.
I understand its interpretation of the dashes-although I've never used them-and why it
results in the error.
I am looking for a way to eliminate them and retain the text in the field.
An example is;
Dl'd value of --AGCY NOT NUMERIC XXXXXXXXX, results in;
=--AGCY NOT NUMERIC XXXXXXXXX
XL inserts the "=" sign and results in the Name error.

Strangely, it is not consistent throughout, for ex;
"--AGCY NOT NUMERIC 04041011"
is OK. The only difference being that the 1st example has "X's in the field whereas

the
second has numbers(?)

At the end of the day I'd like to retain the text value following the dashes.

--
Regards;
Rob
------------------------------------------------------------------------


--

Dave Peterson



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
Special Characters causing problems Vickie Excel Discussion (Misc queries) 1 November 25th 08 09:42 PM
Watermark Causing Print Problems kbellando Excel Discussion (Misc queries) 0 March 15th 08 01:12 AM
Rand () causing Problems. JCary Excel Discussion (Misc queries) 1 March 6th 06 10:38 PM
Splash Screen Causing Problems Kevin R Excel Programming 8 August 17th 05 02:54 PM
Addins causing problems Andrew- Excel Programming 6 June 30th 05 07:25 PM


All times are GMT +1. The time now is 12:49 PM.

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"