Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ISNUMBER

Status
Not open for further replies.

PWD

Technical User
Jul 12, 2002
823
GB
In EXCEL 2000. =IF(ISNUMBER(M9),"NUMBER","NOT") works OK (cell M9 only contains "4") but =IF(ISNUMBER(LEFT(A14,1)),"NUMBER","NOT") doesn't and always comes up as "NOT", i.e FALSE. I'm trying to determine if the first character of a cell is numeric, e.g. where cell A14 is '5-Jan Total' =IF(ISNUMBER(LEFT(A14,1)),"NUMBER","NOT"). Any ideas anyone?
Des.
 
You have to convert the text to a number in order for it to evaluate correctly.

Try this
Code:
=IF(ISNUMBER(VALUE(LEFT(A14,1))),"NUMBER","NOT")

Hope that works. I tried it on my pc and it did.

Nick
 
Just to explain - if you use any of the character functions (Left / Right / Mid), the result returned will be a string ie text. That is why youhave to use the VALUE function to convert to a number

Rgds, Geoff
[blue]Experience is something you don't get until just after you need it[/blue]
We want to help [red]you[/red] Help us by reading this FAQ 1st faq222-2244
 
Yup, works just fine. Thanx Nick. Ah, string - thanks Geoff

Des.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top