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.

Excel Programming Constant Value

Discussion in 'Business Applications' started by acf666ingdc, Sep 2, 2011.

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

    acf666ingdc Thread Starter

    Joined:
    Sep 2, 2011
    Messages:
    7
    I am writing a food costing program in excel to calculate a number of costs, conversions etc. in Microsoft Excel. I have my code working to what I would like it to do but I have hit one snag. I want to be able to copy and paste the code throughout the spreadsheet and I need certain values to remain the same and some to change accordingly.=LOOKUP(A13,Centennial!A6:Centennial!A26,Centennial!E6:Centennial!E26) that is the code and I need the values of the ranges to stay the same(A6,A26,E6,E26) and A13 to change as i copy and paste. How do I keep those values constant?
     
  2. etaf

    etaf Moderator

    Joined:
    Oct 2, 2003
    Messages:
    64,770
    First Name:
    Wayne
    use a $ sign to fix the position

    A6

    to keep the column from changing type

    $A6

    to stop the row changing type

    A$6

    to fix both column and row

    $A$6

    so for your look up range

    $A$6.$A$26
     
  3. acf666ingdc

    acf666ingdc Thread Starter

    Joined:
    Sep 2, 2011
    Messages:
    7
    Thanks exactly what I needed.
     
  4. etaf

    etaf Moderator

    Joined:
    Oct 2, 2003
    Messages:
    64,770
    First Name:
    Wayne
    your welcome (y) thanks for letting us know
    You can mark your own threads solved using the [​IMG] button at the top of the page of the thread in the upper left corner. :)
     
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/1015624

  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