ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   using text as a "true" condition in an if function. (https://www.excelbanter.com/excel-worksheet-functions/184009-using-text-true-condition-if-function.html)

diggyroo

using text as a "true" condition in an if function.
 
I need to write an if function that says when text is enterd in a cell it
needs to return "please enter a value!!!" I cant remember how to define text
in the if function. example. if(A1="text","Please enter a value!!!") I need
it to say that if anything other than a # is entered in the cell beside it.
And ive tried the one i put here and it only works if i put the word text in
the cell.

Thanks for any help


David Biddulph[_2_]

using text as a "true" condition in an if function.
 
You are probably thinking of the ISTEXT function?
--
David Biddulph

"diggyroo" wrote in message
...
I need to write an if function that says when text is enterd in a cell it
needs to return "please enter a value!!!" I cant remember how to define
text
in the if function. example. if(A1="text","Please enter a value!!!") I
need
it to say that if anything other than a # is entered in the cell beside
it.
And ive tried the one i put here and it only works if i put the word text
in
the cell.

Thanks for any help




T. Valko

using text as a "true" condition in an if function.
 
One way:

=IF(ISTEXT(A1),"Enter a number!","")

However, if cell A1 is formatted as TEXT and a number is entered it will be
evaluated as TEXT and return the message.

--
Biff
Microsoft Excel MVP


"diggyroo" wrote in message
...
I need to write an if function that says when text is enterd in a cell it
needs to return "please enter a value!!!" I cant remember how to define
text
in the if function. example. if(A1="text","Please enter a value!!!") I
need
it to say that if anything other than a # is entered in the cell beside
it.
And ive tried the one i put here and it only works if i put the word text
in
the cell.

Thanks for any help




FSt1

using text as a "true" condition in an if function.
 
hi
something like this might work.....
=IF(ISTEXT(A3),"Enter a value","")

Regards
FSt1

"diggyroo" wrote:

I need to write an if function that says when text is enterd in a cell it
needs to return "please enter a value!!!" I cant remember how to define text
in the if function. example. if(A1="text","Please enter a value!!!") I need
it to say that if anything other than a # is entered in the cell beside it.
And ive tried the one i put here and it only works if i put the word text in
the cell.

Thanks for any help


diggyroo

using text as a "true" condition in an if function.
 
Thank you all very much. The funny thing is i new it as soon as i read the
replys. Thanks for the reminder.

"T. Valko" wrote:

One way:

=IF(ISTEXT(A1),"Enter a number!","")

However, if cell A1 is formatted as TEXT and a number is entered it will be
evaluated as TEXT and return the message.

--
Biff
Microsoft Excel MVP


"diggyroo" wrote in message
...
I need to write an if function that says when text is enterd in a cell it
needs to return "please enter a value!!!" I cant remember how to define
text
in the if function. example. if(A1="text","Please enter a value!!!") I
need
it to say that if anything other than a # is entered in the cell beside
it.
And ive tried the one i put here and it only works if i put the word text
in
the cell.

Thanks for any help





T. Valko

using text as a "true" condition in an if function.
 
You're welcome!

--
Biff
Microsoft Excel MVP


"diggyroo" wrote in message
...
Thank you all very much. The funny thing is i new it as soon as i read the
replys. Thanks for the reminder.

"T. Valko" wrote:

One way:

=IF(ISTEXT(A1),"Enter a number!","")

However, if cell A1 is formatted as TEXT and a number is entered it will
be
evaluated as TEXT and return the message.

--
Biff
Microsoft Excel MVP


"diggyroo" wrote in message
...
I need to write an if function that says when text is enterd in a cell
it
needs to return "please enter a value!!!" I cant remember how to define
text
in the if function. example. if(A1="text","Please enter a value!!!") I
need
it to say that if anything other than a # is entered in the cell beside
it.
And ive tried the one i put here and it only works if i put the word
text
in
the cell.

Thanks for any help








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

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