Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 53
Default Operator for Contains

Hi,

I want to do a standard IF function - with a twist.

Basically I want to look at a cell and if it is not a whole number then I
want a certain action and if it is then another action.

I thought I could do this with an IF contains . but this does not seem to
work.

Could anyone please provide some help on this topic.

Thanks
--
Leanne M (Aussie)
(Changed Display name from Leanne)
United Kingdom
(Don''t ask me what an Aussie is doing living in the UK!)
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,646
Default Operator for Contains

Try this:
=IF(MOD(A1,1)=0,"integer","non-integer")

Regards,
Stefi

€˛Leanne M (Aussie)€¯ ezt Ć*rta:

Hi,

I want to do a standard IF function - with a twist.

Basically I want to look at a cell and if it is not a whole number then I
want a certain action and if it is then another action.

I thought I could do this with an IF contains . but this does not seem to
work.

Could anyone please provide some help on this topic.

Thanks
--
Leanne M (Aussie)
(Changed Display name from Leanne)
United Kingdom
(Don''t ask me what an Aussie is doing living in the UK!)

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 75
Default Operator for Contains

Lets assume that the cell you are checking the number in is in A1. Your
formula should be something like:-

=IF(A1=INT(A1),"Whole Number","Decimal Number")

--
Alan Moseley IT Consultancy
http://www.amitc.co.uk


"Leanne M (Aussie)" wrote:

Hi,

I want to do a standard IF function - with a twist.

Basically I want to look at a cell and if it is not a whole number then I
want a certain action and if it is then another action.

I thought I could do this with an IF contains . but this does not seem to
work.

Could anyone please provide some help on this topic.

Thanks
--
Leanne M (Aussie)
(Changed Display name from Leanne)
United Kingdom
(Don''t ask me what an Aussie is doing living in the UK!)

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
Operator kittycris Excel Worksheet Functions 3 January 11th 07 01:36 AM
IN operator Suzanne Excel Worksheet Functions 4 May 10th 06 06:28 PM
XOR Operator - How? Randy Brown Excel Discussion (Misc queries) 3 April 8th 06 09:47 PM
what does ~ operator mean? Todd Excel Discussion (Misc queries) 3 November 22nd 05 05:30 PM
OR Operator Freddy Excel Worksheet Functions 2 April 17th 05 06:11 PM


All times are GMT +1. The time now is 06:49 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"