PDA

View Full Version : Taking input from another worksheet cell in excel 2007



kkj
03-14-2012, 09:46 PM
Hi guys, I want to calculate the total number of entries based on some condition (values greater than 0.2) from A1 to G1. And want to display the result at K1. The value (0.2) works as threshold and will be provided from another worksheet say sheet2 (cell A1).
I have written this formula
=COUNTIF(A1:G1,">=0.2")
But it takes input from Sheet1 (K1).
I want it to take input from sheet2(A1) and calculate in sheet1(K1)
Regards,

TMShucks
03-15-2012, 03:30 AM
I'm a little confused about what you are asking but, as a generalisation, you should be able to say something like:

Sheet1, K1: =COUNTIF('Sheet1'!A1:G1, ">=" & 'Sheet2'!A1)

So, the cell K1 on Sheet 1 counts the values in row 1, cells A1 to G1, on Sheet 1, where they are greater than or equal to the threshold defined in cell A1 on Sheet 2.

Note: you don't actually need to refer to Sheet 1 in formulae on Sheet 1 so this could be:

Sheet1, K1: =COUNTIF(A1:G1, ">=" & 'Sheet2'!A1)

Regards, TMS