#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 65
Default "If" Formula Error

Below is the formula I currently have. I want to get a "1" if the logical
test answer returns a number not equal to 2-16 (a range). So if the number is
less than 2 or greater than 16, I need a 1, otherwise I need "Assign
Division".
How do you put "not equal" in a formula and how do you put "not equal" to a
range of numbers?

=IF(MID(D26,2,2)<216,1,"Assign Division")

Thanks in advance for your help.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 248
Default "If" Formula Error

Try
=IF(OR((0+MID(D26,2,2))*1<2,(0+MID(D26,2,2)16)),1 ,"Assign Division")

0 is added to convert the string returned by MID to a number
-------------------------------------
Pl. click ''''Yes'''' if this was helpful...



"evoxfan" wrote:

Below is the formula I currently have. I want to get a "1" if the logical
test answer returns a number not equal to 2-16 (a range). So if the number is
less than 2 or greater than 16, I need a 1, otherwise I need "Assign
Division".
How do you put "not equal" in a formula and how do you put "not equal" to a
range of numbers?

=IF(MID(D26,2,2)<216,1,"Assign Division")

Thanks in advance for your help.

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 515
Default "If" Formula Error

MMID checks text, not numbers, so MID will cause a problem. MID(D26,2,2)
cannot return a number less than 2, since you are checking 2 digits. The
part will also always evaluate to TRUE.

A little magic though, should do the trick. Change your formula to read
=IF(OR(SUM(MID(D26,2,2)+0)<2,SUM(MID(D26,2,2)+0)1 6),1,"Assign Division")

--
HTH

Kassie

Replace xxx with hotmail


"evoxfan" wrote:

Below is the formula I currently have. I want to get a "1" if the logical
test answer returns a number not equal to 2-16 (a range). So if the number is
less than 2 or greater than 16, I need a 1, otherwise I need "Assign
Division".
How do you put "not equal" in a formula and how do you put "not equal" to a
range of numbers?

=IF(MID(D26,2,2)<216,1,"Assign Division")

Thanks in advance for your help.

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,934
Default "If" Formula Error

I believe this will also work...

=IF(ABS(MID(D26,2,2)-9)7,1,"Assign Division")

--
Rick (MVP - Excel)


"Sheeloo" just remove all As... wrote in
message ...
Try
=IF(OR((0+MID(D26,2,2))*1<2,(0+MID(D26,2,2)16)),1 ,"Assign Division")

0 is added to convert the string returned by MID to a number
-------------------------------------
Pl. click ''''Yes'''' if this was helpful...



"evoxfan" wrote:

Below is the formula I currently have. I want to get a "1" if the logical
test answer returns a number not equal to 2-16 (a range). So if the
number is
less than 2 or greater than 16, I need a 1, otherwise I need "Assign
Division".
How do you put "not equal" in a formula and how do you put "not equal" to
a
range of numbers?

=IF(MID(D26,2,2)<216,1,"Assign Division")

Thanks in advance for your help.


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
"Document not saved" "error in loading DLL" Tracey L Excel Discussion (Misc queries) 0 December 1st 08 12:57 PM
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
Shortcut key for "Paste Options" and "Error Checking" buttons? johndog Excel Discussion (Misc queries) 1 October 6th 06 11:56 AM
VBA setting formula for a cell causes "Wrong data type" error undercups Excel Discussion (Misc queries) 4 September 17th 06 10:14 PM
How do I replace "#N/A" error, to continue my formula w/o error? Ali Khan Excel Worksheet Functions 2 February 20th 06 03:49 PM


All times are GMT +1. The time now is 02:08 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"