+ Reply to Thread
Results 1 to 6 of 6

If/then with case statement

  1. #1
    Registered User
    Join Date
    02-01-2013
    Location
    denver
    MS-Off Ver
    Excel 2003
    Posts
    17

    Cool If/then with case statement

    Attached Excel Sheet.


    If record 2 (B Column minus header) contains zero, put the value "ZZ"; however if the value is greather than zero go to Record 1 (Column A) to determine the value in the case statment and populate the value in Record 3 (Column C)


    Highlighted in yellow are the correct answers.

    Thank you.
    Attached Files Attached Files
    Last edited by nhi; 05-29-2013 at 04:31 PM.

  2. #2
    Valued Forum Contributor tehneXus's Avatar
    Join Date
    04-12-2013
    Location
    Hamburg, Germany
    MS-Off Ver
    Work: MS-Office 2010 32bit @ Win8 32bit / Home: MS-Office 2016 32bit @ Win10 64bit
    Posts
    944

    Re: If/then with case statement

    formula for C2:
    Please Login or Register  to view this content.
    Please use [CODE]-TAGS
    When your problem is solved mark the thread SOLVED
    If an answer has helped you please click to give reputation
    Read the FORUM RULES

  3. #3
    Registered User
    Join Date
    02-01-2013
    Location
    denver
    MS-Off Ver
    Excel 2003
    Posts
    17

    Re: If/then with case statement

    Thanks, however I need a VBA formulation.

  4. #4
    Valued Forum Contributor tehneXus's Avatar
    Join Date
    04-12-2013
    Location
    Hamburg, Germany
    MS-Off Ver
    Work: MS-Office 2010 32bit @ Win8 32bit / Home: MS-Office 2016 32bit @ Win10 64bit
    Posts
    944

    Re: If/then with case statement

    As a loop for the data in the sample:
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    02-01-2013
    Location
    denver
    MS-Off Ver
    Excel 2003
    Posts
    17

    Re: If/then with case statement

    Is there anyone to make the program dynamic with ranges, whereas lets say the range of Record 1 (Column A) is changing. ( For i = 2 to n?)

  6. #6
    Valued Forum Contributor tehneXus's Avatar
    Join Date
    04-12-2013
    Location
    Hamburg, Germany
    MS-Off Ver
    Work: MS-Office 2010 32bit @ Win8 32bit / Home: MS-Office 2016 32bit @ Win10 64bit
    Posts
    944

    Re: If/then with case statement

    Please Login or Register  to view this content.
    till last row of data in column A

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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