UDF not recognized after conversion to 2007

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

A UDF that was working fine in Excel 2003 is returning a #NAME? error in
2007. The function is called from a cell. There is nothing else in the cell
but a call to this function. Everything on the call line evaluates correctly
except the name of the function, or the function itself, which evaluates to
the #NAME? error. I've checked the VB side and the function is declared
public in a module.

Not sure what's holding 2007 back from running this function. Has anyone
experienced this before?

Thanks.
 
Did you enable macros when you opened the workbook that contains the UDF?

If you select the cell and hit F2, then enter, does it evaluate correctly?
 
Bingo! Thank you! They were disabled. Funny thing, though, is that when I
opened another workbook that contained macros, I got the usual message I used
to see in 2003 asking me if I wanted to enable macros. On this one (the one
in question in this thread) I got no such message. Also, when I went to the
macro settings in the Trust Center, I no longer see an option in 2007 to be
prompted if macros exist. There are several options to disable macros and the
only one that seems to allow macros is the most dangerous one: enable macros.

If you have any insights on these comments, I'd be interested in hearing
them; otherwise, thank you very much for this help!
 
I don't use xl2007 much, but if I open a workbook that contains code, there's a
message/prompt at the top of the worksheet window asking me if I want to enable
macros.
 
Thanks for all your help.

Dave Peterson said:
I don't use xl2007 much, but if I open a workbook that contains code, there's a
message/prompt at the top of the worksheet window asking me if I want to enable
macros.
 

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

Back
Top