BUG: You receive an error "Undefined Function '{FunctionName}' in Expression" when you open a Data Access Page in Access 2002 (274379)



The information in this article applies to:

  • Microsoft Access 2002

This article was previously published under Q274379
Moderate: Requires basic macro, coding, and interoperability skills.

For a Microsoft Access 2000 version of this article, see 304755.
For a Microsoft Office Access 2003 version of this article, see 824279.

SYMPTOMS

In a data access page, if you call a function that is not available outside of Microsoft Access, you receive the following message when you open the page in Microsoft Internet Explorer:
Data Provider failed executing a provider command.
This message is followed by another message:
Undefined function '{FunctionName}' in expression.
This error does not occur when you open the data access page in Access.

CAUSE

When you open the page in Internet Explorer, certain Access-specific functions are not available. For example, you see this message if your data access page is based on a query in which an expression contains Nz(), EuroConvert(), Eval(), or a user-defined function.

You also receive this message if you use one of these functions in a control (such as a text box) on a data access page.

RESOLUTION

This is a known limitation of data access pages.

However, two of these functions, Nz() and Euroconvert(), have been added as methods of the Microsoft Data Source Control (MSODSC) object. If you want to use Nz() and Euroconvert() in a data access page, you can do so by using the following syntax:

Euroconvert Method
MSODSC.Euroconvert(50,"FRF","EUR",False,3)
				
Nz Method
MSODSC.Nz([NumericValueHere],0)
				

STATUS

This issue is documented in the Access 2002 Readme file, included with Microsoft Access.

MORE INFORMATION

For more information about about these and other methods of the DataSourceControl object, in the Visual Basic Editor, click Microsoft Visual Basic Help on the Help menu, type DataSourceControl Methods in the Office Assistant or the Answer Wizard, and then click Search to view the topic.

Modification Type:MinorLast Reviewed:9/27/2006
Keywords:kbProgramming kbtshoot kbbug kbDAPScript kberrmsg kbnofix KB274379