Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
NEWB
 
Posts: n/a
Default Storing Formulas to Use

Is there a way to store formulas in a worksheet, for instance----
=IF(ISNA(VLOOKUP(A4,'2005 information'!$A$4:$L$97,12,FALSE)),"No Client Info
For This Year",VLOOKUP(A4,'2005 information'!$A$4:$L$97,12,FALSE)) ----- So
that it will automaticall pull if a new worksheet is created. Basically I
want to make a Comparison worksheet, and when a new year comes like 2006, I
want ot be able to pull in my 2006 worksheet, and have the formulas update
automatically to 2006, so that I don't have to change them to 2006. Is this
possible to do????
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
vezerid
 
Posts: n/a
Default Storing Formulas to Use

You need the INDIRECT() function, which creates dynamic addresses.
Assuming that you have your year number in a separate cell (Say K1),
and that all your worksheets have the same format, i.e. "YEARNO(space)
information", you will need the following for your VLOOKUP():
VLOOKUP(A4, INDIRECT("'" & K1 & " information'!$A$4:$L$97"), 12, FALSE)

HTH
Kostis Vezerides

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
NEWB
 
Posts: n/a
Default Storing Formulas to Use

what do you mean by having the year number in a seperate cell, because I did
that, and my vlookup does not update if i put 2004 in it stays as the 2005
numbers.

"vezerid" wrote:

You need the INDIRECT() function, which creates dynamic addresses.
Assuming that you have your year number in a separate cell (Say K1),
and that all your worksheets have the same format, i.e. "YEARNO(space)
information", you will need the following for your VLOOKUP():
VLOOKUP(A4, INDIRECT("'" & K1 & " information'!$A$4:$L$97"), 12, FALSE)

HTH
Kostis Vezerides


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
vezerid
 
Posts: n/a
Default Storing Formulas to Use

Newb,
first of all the full formula, in case you forgot something:

=IF(ISNA(VLOOKUP(A4, INDIRECT("'" & K1 & " information'!$A$4:$L$97"),
12, FALSE)),"No Client Info For This Year",VLOOKUP(A4, INDIRECT("'" &
K1 & " information'!$A$4:$L$97"), 12, FALSE))

Second, I just tested a variant, just in case and it works. Please
check Tools|Options the Calculation tab, to see if somehow calculation
was set to Manual. If so, you would get the new values by pressing the
function key F9.

Finally, replace K1 in BOTH places in the formula with whatever cell
you chose in your Comparison sheet.

Write back if neither of these works.

Kostis Vezerides

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
how can i get formulas in excel to copy and paste? bman Excel Worksheet Functions 1 October 3rd 05 04:15 PM
Array Formulas take waaaay too long... belly0fdesire Excel Worksheet Functions 7 August 8th 05 10:11 PM
locking formulas?? Rob Excel Discussion (Misc queries) 1 July 27th 05 09:27 AM
Problem with named formula's nathan Excel Worksheet Functions 0 January 21st 05 04:07 PM
calculating formulas for all workbooks in a folder Chad Excel Worksheet Functions 3 November 13th 04 05:22 PM


All times are GMT +1. The time now is 07:06 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"