I've done a lot of database work, but only scratched the surface with Access. I'm trying to write a macro (executable on-click from a button on a form) that will clear a subset of the current record's fields.
My macro is pretty simple-minded: It has eight actions (all SetValue), each one associated with one of eight fields ("items", right?--selected off the table's field list), and each target expression is simply "null".
I've associated the macro with the button on the form, but when I click the button, I get the following pop-up error:
--------------------------------------------------------------
The object doesn't contain the Automation object 'my_database.'
You tried to run a Visual Basic procedure to set a property or method for an object. However, the component doesn't make the property or method available for Automation operations.
Check the component's documentation for information on the properties and methods it makes available for Automation operations.
--------------------------------------------------------------
Is the "component" my database? My macro? I've been unable to find any a property associated with anything that speaks to "Automation-ability."
Since the macro dies at the first call, I changed the order of the fields, just on the off-chance that something just happened to be wrong with that first call. Same thing.
My macro is pretty simple-minded: It has eight actions (all SetValue), each one associated with one of eight fields ("items", right?--selected off the table's field list), and each target expression is simply "null".
I've associated the macro with the button on the form, but when I click the button, I get the following pop-up error:
--------------------------------------------------------------
The object doesn't contain the Automation object 'my_database.'
You tried to run a Visual Basic procedure to set a property or method for an object. However, the component doesn't make the property or method available for Automation operations.
Check the component's documentation for information on the properties and methods it makes available for Automation operations.
--------------------------------------------------------------
Is the "component" my database? My macro? I've been unable to find any a property associated with anything that speaks to "Automation-ability."
Since the macro dies at the first call, I changed the order of the fields, just on the off-chance that something just happened to be wrong with that first call. Same thing.
Comment