using CountIF to goto range in the correct month sheet?

lpking2005

Board Regular
Joined
Mar 21, 2011
Messages
140
Is it possible to tell a formula bar to pull a range from the correct month tab in another workbook?

I have this in a table of cells:

=COUNTIF('[403 CTI 2011.xls]AUG-11'!$I$5:$I$42,"")

As you can see, it goes to the "AUG-11" sheet because of the range i selected.
I need it to always read the correct data for the correct month.

Does anyone know if this is possible or a workaround?

Thannks!
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
take a look at the INDIRECT function

it will take me a while to work out the correct syntax
 
Upvote 0
=COUNTIF(INDIRECT("'[403 CTI 2011.xls]'" & A1 & "!$I$5:$I$42"),"")


where A1 holds AUG-11 or whatever, i think i have it correct give it a try
 
Upvote 0
Thanks for the reply, but i still cannot get this to work.

I will explain what i need a bit more, in case its my fault.

In workbook1, i have a group of cells which need this formula in each cell:

6054926849_7e1b73b6c9_m.jpg
[/url]
cti cells by lpking2005, on Flickr[/IMG]

each cell turns either Red or Green based on how many cells have been filled out on the "403 CTI 2011" workbook.

The "403 CTI 2011" workbook is yearly based, so every sheet is named by month/year. eg. "AUG-11", "SEP-11" and so on.

There is a cell on each sheet which says the name of the sheet also, if that helps. Plus i have coded it to always open the workbook at the correct month.

6055487006_b390649bc6_z.jpg
[/url] cti sheet by lpking2005, on Flickr[/IMG]

I hope this explains it more clearly
 
Upvote 0

Forum statistics

Threads
1,224,613
Messages
6,179,894
Members
452,948
Latest member
Dupuhini

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top