+ Reply to Thread
Results 1 to 4 of 4

nested if statement with and,or and not

  1. #1
    Registered User
    Join Date
    07-10-2007
    Location
    Turkey-Bartın/
    MS-Off Ver
    Ms Office-2007
    Posts
    44

    nested if statement with and,or and not

    Hi
    I want to delete the rows that has 1 or 2.. I mean :
    AB---CD--EF-
    12....00...00....00 This row must be removed because it has 1 in col A and 2 in col B
    00....11...22....11 This row mustnt be removed because it doesnt have 1 and 2 side by side
    or let me put it that way
    If ((a1=1 and b1=2) and (a1=2 and b1=1),and (c1=1 and d1=2) and( c1=2 and d1=1)......range up to Column "F"...."delete")
    please have a look at the attachment file.

    Thanks
    Attached Files Attached Files

  2. #2
    Forum Contributor
    Join Date
    05-24-2013
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    291

    Re: nested if statement with and,or and not

    Hi Gencoglu,

    Put this in column H

    =IF(OR(SUM(A1:B1)=3,SUM(C1:D1)=3,SUM(E1:F1)=3),"Remove","Ok")

  3. #3
    Registered User
    Join Date
    07-10-2007
    Location
    Turkey-Bartın/
    MS-Off Ver
    Ms Office-2007
    Posts
    44

    Re: nested if statement with and,or and not

    Thank you amy_d2
    Your code worked nice..

  4. #4
    Forum Contributor
    Join Date
    05-24-2013
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    291

    Re: nested if statement with and,or and not

    M Glad.....

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Nested If Statement - ISBLANK and ISNA in same statement?
    By Janc in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 04-23-2013, 09:00 AM
  2. [SOLVED] Nested if statement
    By pamc in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 03-08-2013, 11:43 AM
  3. [SOLVED] Help please if possible with nested IF statement I think
    By AnneFr in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 11-02-2012, 09:16 AM
  4. need with nested if statement
    By dip79 in forum Excel General
    Replies: 3
    Last Post: 04-04-2011, 07:25 AM
  5. Replies: 6
    Last Post: 01-14-2009, 06:59 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1