M
Michael Zeile
hi there,
i have the following problem:
i have 2 normal Windows Forms classes, declared as:
public __gc class MainForm : public System::Windows::Forms::Form
and
public __gc class FormLayout : public System::Windows::Forms::Form
my application starts like this:
....
MainForm *myform;
myform = new MainForm();
System::Threading::Thread::CurrentThread->ApartmentState =
System::Threading::ApartmentState::STA;
Application::Run(myform);
....
somewhere in my MainForm class, i have the following code:
....
FormLayout *formLayout;
formLayout = new FormLayout();
formLayout->Show();
formLayout->InitGL();
....etc...
now my problem: i want to send status messages or change the behavior of
my MainForm window by pressing a key in my FormLayout form, but i can't
because i don't know the instance of my MainForm ... because __gc
objects can't be declared global. so how do i get the instance of my
form generated by Application::Run() ?
any suggestions ?
thx a LOT...
bye
michael
i have the following problem:
i have 2 normal Windows Forms classes, declared as:
public __gc class MainForm : public System::Windows::Forms::Form
and
public __gc class FormLayout : public System::Windows::Forms::Form
my application starts like this:
....
MainForm *myform;
myform = new MainForm();
System::Threading::Thread::CurrentThread->ApartmentState =
System::Threading::ApartmentState::STA;
Application::Run(myform);
....
somewhere in my MainForm class, i have the following code:
....
FormLayout *formLayout;
formLayout = new FormLayout();
formLayout->Show();
formLayout->InitGL();
....etc...
now my problem: i want to send status messages or change the behavior of
my MainForm window by pressing a key in my FormLayout form, but i can't
because i don't know the instance of my MainForm ... because __gc
objects can't be declared global. so how do i get the instance of my
form generated by Application::Run() ?
any suggestions ?
thx a LOT...
bye
michael