Set value of cell to calculation

W

WembleyBear

I have two spreadsheets – one is called Branch A and one is called Company.
Branch A contains financial information, but only for the current month.
Company is a summary which has columns for each of the months, January,
February etc. At the top of this spreadsheet is a drop-down box with the
current month in it called CURRMONTH.

What I need is to be able to make a calculation from Branch A and have it
place the result in the relevant column on the Company spreadsheet. The
calculation is:

=[Branch A.xls]Main!A102-[Branch A.xls]Main!A103

but it needs to go in the correct column based on what month is selected in
the CURRMONTH drop-down. How do I do this?

Thanks for your help

Martyn
 
N

Nigel

If the dates are in order then the LINK cell for the control (if Form
control) will return the control list number, if an activeX control then use
the ListIndex property that will return the selected control entry -1, you
can use this directly to offset your target cell.

If dates are not in order then use a VLOOKUP to take the value from the
control, lookup this value in a control table and get the cell reference
into which you wish to place the value.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top