View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default "Number Formatted As Text": How To Avoid?

Could you just format the range as General and let the CUSIP be numeric or text
just as they are??

Or if it's numeric and have to have a certain number of digits, give it a custom
format like: 000000000.

Or you could turn off that error checking with something like:
Application.ErrorCheckingOptions.NumberAsText = False





"(PeteCresswell)" wrote:

I'm populating a worksheet with various types of data.

A couple of columns are different types of CUSIP.

e.g.
---------------------------------------
5180 Case mFieldID_CUSIP_144a
5181 mColNum_CUSIP_144a = curCol
5182 With .Columns(curCol)
5183 .ColumnWidth = mColWid_CUSIP
5184 .NumberFormat = "@"
5189 End With
---------------------------------------

Most CUSIPs are alphameric, but a few are all numeric.

e.g. "774272207"

For those few, the populated sheet shows that little green triangle in the upper
left of the cell and clicking it pops a micro-dialog whose MouseOver presents
"The number in this cell is formatted as text or is proceeded by an apostrophe".

Is there any way for me to avoid inflicting that little chain of events on the
user?
--
PeteCresswell


--

Dave Peterson