+ Reply to Thread
Results 1 to 5 of 5

I'm trying to do something with IF

  1. #1
    Registered User
    Join Date
    03-05-2014
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    21

    I'm trying to do something with IF

    Hi All

    I'm trying to do something which I thought was simple using conditions but I cant get it to work.

    I have 2 datasheets which are supposed to pull only selected rows of sales opportunity data into a commission sheets based on conditions such as salesman (using Initials) and whether an opportunity was converted into a sale. I have used IF functions to return my results however I get blank rows where FALSE is the return.

    I know this is easy to do just using filters however this is not the method I want to use.

    I have enclosed an example of the data and the output I currently get.

    If anyone knows how to remove the empty rows or knows a better way, it would be a big help.

    Thanks

    PJR
    Attached Files Attached Files

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: I'm trying to do something with IF

    Hi,

    The better, (much better) way is of course the data filter functionality which was designed precisely for the task you're doing. What have you got against using data filter which could be a simple one line macro similar to the following.

    Please Login or Register  to view this content.
    This could be run automatically on the click of a button and with a dynamic range name for your 'MyData' range completely free of any input or changes to ranges.

    There are no doubt additional functions you could build into your existing formulae but these would complicate the system immensely even without a helper column or two, which would probably be necessary to identify where the gaps are and compensate with an OFFSET function.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,655

    Re: I'm trying to do something with IF

    Try these Array Formulas. Since these are Array Formulas so you need to confirm them with Ctrl + Shift + Enter instead of just Enter. (i.e. hold down the Ctrl+Shift and then press Enter)

    On Sheet MB Commission - New Sales
    In cell A2
    Please Login or Register  to view this content.
    and then drag across and down.

    On Sheet MB Commission- Repeat Sales
    In cell A2
    Please Login or Register  to view this content.
    and then drag across and down.

    For detail see the attached sheet.
    Attached Files Attached Files
    Regards
    sktneer


    Treat people the way you want to be treated. Talk to people the way you want to be talked to.
    Respect is earned NOT given.

  4. #4
    Registered User
    Join Date
    03-05-2014
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    21

    Re: I'm trying to do something with IF

    Thanks all for looking at this.

    sktneer your solution works great for me.

  5. #5
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,655

    Re: I'm trying to do something with IF

    Glad to help you. Thanks for the feedback.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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