Set Field Default Value

  • Thread starter Thread starter Adept
  • Start date Start date
A

Adept

Access Help says I can set the default value with a macro or VB.

When I enter the macro (or vb function) name in the default value property
and then save, the error message says that the function is not recognized.

The Functions/Macros do not show up in the Expression Builder either.

Roger
 
Adept said:
Access Help says I can set the default value with a macro or VB.

When I enter the macro (or vb function) name in the default value
property and then save, the error message says that the function is
not recognized.
The Functions/Macros do not show up in the Expression Builder either.

Roger

Saying that you can set the DefaultValue property WITH a macro does not mean you
can set the DefaultValue property TO the name of a macro.

You can enter into the property a VBA function that returns a value, but you
cannot put a macro name in there. Even with a VBA function it depends on where
you do it. For the DefaultValue property on a control on a form you can use
just about any function (even user defined ones). For the DefaultValue property
in a Table's design you are much more limited. You can only use functions that
the Jet database engine can evaluate directly without help from the expression
service in Access.
 

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