Item_CustomProperty fires before Item_Open?

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

Guest

Hi,

Is that supposed to happen? I was under the impression that to initialise
variables its good practice to do it under Item_Open since it is called once
the form is opened.

Whats happening is the CustomPropertyChange event fires off first and raises
an error since it refers to an object that has not yet been initialised hence
"Object required" error message.

Am I perhaps doing something wrong or is this normal and my only real
workaround is to handle the error?
 
Yes, that can definitely happen. The simple solution is to use a module-level Boolean variable to track whether the Open event has fired yet.
 
Back
Top