Hi,
I had a simple command button with an embedded macro object. The macro simply copied a value from one textbox to the other on the same form.
The macro was simple using the SetProperty function and worked without issues.
I then transfered the macro to VBA automatically and the result was:
DoCmd.SetProperty in VBA, DoCmd.SetProperty "txtbox1", acPropertyValue, txtbox2
This works perfert if txtbox1 has a value. If it s NULL I get the error message that the data format is wrong. As an embedded macro it works fine even if the txtbox was NULL.
Can anyone help me make this work even if the value of txtbox1 = NULL?
Thanks!
I had a simple command button with an embedded macro object. The macro simply copied a value from one textbox to the other on the same form.
The macro was simple using the SetProperty function and worked without issues.
I then transfered the macro to VBA automatically and the result was:
DoCmd.SetProperty in VBA, DoCmd.SetProperty "txtbox1", acPropertyValue, txtbox2
This works perfert if txtbox1 has a value. If it s NULL I get the error message that the data format is wrong. As an embedded macro it works fine even if the txtbox was NULL.
Can anyone help me make this work even if the value of txtbox1 = NULL?
Thanks!