Results 1 to 5 of 5
  1. #1
    Join Date
    Sep 2006
    Posts
    162

    Unanswered: nested if, or a better way to do it

    i have a row with 45 columns on sheet a that reference to a row on sheet b
    Its duplicated 40 times sheet a, this way i can change the change the data on sheet b and it will be changed all 40 times.

    what i want to so is add a control on sheet a like so.

    if cell A1 = 1 then use data from this row on sheet b
    if cell A1 = 2 then use data from this row on sheet b
    and so on

    Should i use a nested if or is there a simpler better way to do this?

  2. #2
    Join Date
    Jul 2003
    Location
    Michigan
    Posts
    1,941
    Probably depends on how deep your IF has to go. Is it a choice between 2 values or 30 values?

    If it's just 2, use a nested if. If it's a bunch, you may want to use a macro.
    Inspiration Through Fermentation

  3. #3
    Join Date
    Sep 2006
    Posts
    162
    its just 3, thanks

  4. #4
    Join Date
    Jul 2003
    Location
    Michigan
    Posts
    1,941
    Yeah, you shouldn't even notice a performance issue at that level.
    Inspiration Through Fermentation

  5. #5
    Join Date
    Oct 2003
    Posts
    1,091
    With that few it shouldn't be a problem. An alternative if it is more is to use a lookup table, which doesn't require VBA.
    old, slow, and confused
    but at least I'm inconsistent!

    Rich
    (retired Excel 2003 user, 3/28/2008)

    How to ask a question on forums

Posting Permissions

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