1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

I think I may need a macro....not sure

Discussion in 'Business Applications' started by RileyandFredsMom, Feb 7, 2007.

Thread Status:
Not open for further replies.
Advertisement
  1. RileyandFredsMom

    RileyandFredsMom Thread Starter

    Joined:
    Feb 7, 2007
    Messages:
    2
    I will try to explain this clearly, but please, if it is convulted, please ask for clarification.

    I have created an Excel Spreadsheet based on a contract we have at work. This contract has multiple areas that require formulas, for instance, if you have X number of sq. footage, you get X number of graphics, etc. I am stuck on 2 formulas that I think will need to be macros and I have no idea how to do one. Please help.

    The contract states:

    For X number of sq. ft. of space, you get X number of lounges, see below for breakdown:

    50,000 - 100,000 sq. ft: 400 sq. ft
    100,001 - 200,000 sq. ft: 600 sq. ft
    200,001 - 300,000 sq. ft: 800 sq. ft
    300,001 - 400,000 sq. ft: 1,000 sq ft
    400,001 + sq ft: 1,200 sq ft

    The spreadsheet is set up so that in the B1 cell, I can enter the total sq. footage and all the cells underneath (B2 - B12) automatically compute based on the number in B1. That is what I would like to happen in this cell (B13)....based on on what I enter in B1, this cell will return the correct sq. ft of lounges (based on breakdown of above).

    I can't figure out a compound IF/THEN statement that will make this work. Can someone please help me? Is this going to have to be a Macro? If so, I have never done one and will need a little help.

    Thanks!
    Shannon
     
  2. Rollin_Again

    Rollin_Again

    Joined:
    Sep 4, 2003
    Messages:
    4,912
    Here is a very simple formula you can use. :D

    I'm not sure if there is an easier way to do this but it seems to work. Now I have a headache.

    =IF(AND(OR(B1>50000,B1=50000),OR(B1<100000,B1=100000)),400,IF(AND(OR(B1>100001,B1=100001),OR(B1<200000,B1=200000)),600,IF(AND(OR(B1>200001,B1=200001),OR(B1<300000,B1=300000)),800,IF(AND(OR(B1>300001,B1=300001),OR(B1<400000,B1=400000)),1000,IF(OR(B1>400001,B1=400001),1200,)))))

    Rollin
     
  3. RileyandFredsMom

    RileyandFredsMom Thread Starter

    Joined:
    Feb 7, 2007
    Messages:
    2
    Thank you Rollin.....I have 2 cells I can use this in, now I've got to figure out the other 2 and I will be all set on this workbook. The other 2 formulas are even more involved but hopefully, by combining the one you just gave me with a couple of basic SUM formulas, I can get this other one worked out.

    Thank you very much! I thought I was losing my mind, I knew it could be done, I just haven't been able to figure it out.
     
  4. Rollin_Again

    Rollin_Again

    Joined:
    Sep 4, 2003
    Messages:
    4,912
    I just made a slight change to the formula above. Please re-copy and paste into your workbook. Let me know if I can be any more help!

    Regards,
    Rollin
     
As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/542113

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice