F FARAZ QURESHI Dec 29, 2007 #1 Can any friend explain to me what is the following part of code means: Application.Caller.Parent.Evaluate
Can any friend explain to me what is the following part of code means: Application.Caller.Parent.Evaluate
D Dave Peterson Dec 29, 2007 #2 I bet that this was used in a UDF. If I'm right... Application.caller would be the cell that held the UDF. application.caller.parent would be the worksheet that held that cell. application.caller.parent.evaluate means to use that worksheet for any unqualified ranges in the string that is being evaluated. msgbox worksheets("sheet1").evaluate("a1+b1") and msgbox worksheets("sheet2").evaluate("a1+b1") would use A1 and B1 from Sheet1 and Sheet2 (respectively)
I bet that this was used in a UDF. If I'm right... Application.caller would be the cell that held the UDF. application.caller.parent would be the worksheet that held that cell. application.caller.parent.evaluate means to use that worksheet for any unqualified ranges in the string that is being evaluated. msgbox worksheets("sheet1").evaluate("a1+b1") and msgbox worksheets("sheet2").evaluate("a1+b1") would use A1 and B1 from Sheet1 and Sheet2 (respectively)
B Bob Phillips Dec 30, 2007 #3 Dave Peterson said: I bet that this was used in a UDF. If I'm right... Click to expand... It was. It was something I gave him.
Dave Peterson said: I bet that this was used in a UDF. If I'm right... Click to expand... It was. It was something I gave him.
D Dave Peterson Dec 30, 2007 #4 It looked like your typing <vbg>. Bob said: It was. It was something I gave him. Click to expand...