Unable to populate a range with a formula
The parethesis is definetly needed. If you are still gettting #NAME then is
can't find the function. With Excel 2003 this is usually becvause the
function has been put into the wrong type Page in the VPA Project or is in
the wrong workbook (like personal.xls). Make sure you put the Function into
a MODULE sheet.
"MichaelDavid" wrote:
Another possibility: Perhaps, with certain Excel setups, one has to register
a new User Defined Function with Excel.
--
May you have a most blessed day!
Sincerely,
Michael Fitzpatrick
"MichaelDavid" wrote:
Greetings! This one has me stumped. I am trying to populate a range with a
formula. The code is:
Sub TestSetAC2()
Range("AC2:AC10").Formula = "=SetAC2"
Exit Sub
End Sub
Function SetAC2()
SetAC2 = 5
End Function
First I opened a blank worksheet. When I execute the procedure, I get #Name?
thruout the range. The tool tip just to the left of #Name? says that the
formula contains unrecognized text. Any help will be greatly appreciated.
--
May you have a most blessed day!
Sincerely,
Michael Fitzpatrick
|