Accessing Form Controls
hi,
I have one problem, Please help me solve this.
Consider there are two forms. Form1 and Form2.
Form1 has - a command button and a text box.
Form2 has - a command button and a text box.
I want to access the controls in form1 from form2.
and also the controls in form2 from form1.
Thanks in advance
Raj
[372 byte] By [
devrds] at [2007-11-18 17:37:17]

# 1 Re: Accessing Form Controls
Are these modeless dialogs? Otherwise how can they both be active?
I suggest that the values from your controls should be sent to the document. Then either dialog could access the values from the common document.
Alternately you might want to consider two property pages under the same property sheet. Then all of the values could be saved at the property sheet level and either property page could use "GetParent()" to get a pointer to the property sheet.
# 2 Re: Accessing Form Controls
look at NativeWindow sample in MSDN, hope it helps...