wvandenberg
Technical User
Hi all,
I have two forms, FormA and FormB and Form A has a treeview control and two listviews. I open FormB with a button on FormA. I enter data into FormB and when it closes I set the focus back to FormA. I am trying to reload the treeview when I set the focus back to FormA so it reflects the new information I've entered in FormB. The code to load the treeview is contained in the OnOpen event of FormA so I tried making the Form_Open event of FormA public and then called it from the OnClose event on FormB but I get and error. I also tried making another public sub called RefreshTree in which I call the Form_Load event of FormA and I get the same error (2465 Application-defined or object-defined error).
Is it possible to call the Form_Load event from another form or do I have to go about this some other way? I know I've done something like this before but I just can't get this on to work.
Thanks in advance,
Wendy
I have two forms, FormA and FormB and Form A has a treeview control and two listviews. I open FormB with a button on FormA. I enter data into FormB and when it closes I set the focus back to FormA. I am trying to reload the treeview when I set the focus back to FormA so it reflects the new information I've entered in FormB. The code to load the treeview is contained in the OnOpen event of FormA so I tried making the Form_Open event of FormA public and then called it from the OnClose event on FormB but I get and error. I also tried making another public sub called RefreshTree in which I call the Form_Load event of FormA and I get the same error (2465 Application-defined or object-defined error).
Is it possible to call the Form_Load event from another form or do I have to go about this some other way? I know I've done something like this before but I just can't get this on to work.
Thanks in advance,
Wendy