Forum Discussion

Misshexadecimal23's avatar
Misshexadecimal23
Copper Contributor
Aug 31, 2021

Excel IF and OR Formula Help

I tried on my own but I have confused myself.  Trying to write excel formulas for all same spreadsheet parameters:

1. "if" column H is blank then pull data from column G or column I (which ever one contains a valid mailing address).

2. "if" column N is blank but column P has data, copy data to column N

3. "if" column P is blank but column N has data, copy it to column P

Any help is much appreciated as I made my own head spin trying to figure this out how to combine if and or formulas.  I am not sure that's even what's needed.

 

5 Replies

  • mathetes's avatar
    mathetes
    Gold Contributor

    Misshexadecimal23 

     

    Do you have an actual spreadsheet in which you want to accomplish this? Can you post a copy? [If the actual contains real names of real people, then make a mock-up of at least a few of the rows that illustrate the problems you're trying to solve.]

     

    That said, some questions that need to be asked or points that need to be made with regard to your questions.

    1. "if" column H is blank then pull data from column G or column I (which ever one contains a valid mailing address).

    Pull data to which column? It can't be column H that contains the formula because then it's not blank to begin with. What do you want done if both G and I have valid addresses? [By the way, it's a mistake to include an entire address in a single cell.] So you would need to be doing this IF....THEN in some other column altogether, perhaps column  J.

     

    2. "if" column N is blank but column P has data, copy data to column N

    3. "if" column P is blank but column N has data, copy it to column P

    Similar to what I said above, these IF...THEN formulas would need to be in a cell in a column other than N or P, because a formula in one of those columns means it's not blank.

     

    Any help is much appreciated as I made my own head spin trying to figure this out how to combine if and or formulas. I am not sure that's even what's needed.

    It could be that you're trying to do what I just pointed out won't work, making a cell not be blank by entering a formula in it that checks whether or not it's blank.

     

    In any event, if you could post a copy (or a mock-up) of what you're working with, then we can offer some specific help.

     

    • Misshexadecimal23's avatar
      Misshexadecimal23
      Copper Contributor

      mathetes 

      Cust NoDivisionCust NameJob DescriptionInfluencer NameTitleAddress 1Address 2Address 3
      43Gexample 1salesjohn doeOWNERexample 1PO BOX 159 
      • Misshexadecimal23's avatar
        Misshexadecimal23
        Copper Contributor
        sorry that didn't copy columns over:
        Cust No. is Column A and then consecutive letters from left to right thereafter.
  • Misshexadecimal23 

    This would require VBA. Do you want it to run automatically when the user enters data in columns G, I, P or N? Or would it be OK to run the code on demand?