S
Steven Edison
I have a split container on my form,
from within one of them I wish to reach
the main form of the app. I'm having
problems with the headers and namespaces.
I want something like this:
//within right pane form
ABCForm^ abcForm = (ABCForm^)Application::OpenForms["ABCForm"];
abcForm->ExecutePublicFunction();
If I include the main form header I get:
'ABCForm' : undeclared identifier
'abcForm' : undeclared identifier
syntax error: ')'
and many more....
The two forms are of the same namespace.
if within the namespace I do this:
namespace ABC{
ref class VPEForm;
public ref class OtherForm : public Form
{
the line:
ABCForm^ abcForm = (ABCForm^)Application::OpenForms["ABCForm"];
will compile without complaint. But then the line:
abcForm->ExecutePublicFunction();
I get:
use of undefined type : 'ABC:ABCForm'
Like it sees the 'ref class VPEForm' as the complete definition of
the class.
So what's the proper way to reference the other form and handle
the includes and namespace from another form?
This should be simple I know...
Thanks,
Steven
from within one of them I wish to reach
the main form of the app. I'm having
problems with the headers and namespaces.
I want something like this:
//within right pane form
ABCForm^ abcForm = (ABCForm^)Application::OpenForms["ABCForm"];
abcForm->ExecutePublicFunction();
If I include the main form header I get:
'ABCForm' : undeclared identifier
'abcForm' : undeclared identifier
syntax error: ')'
and many more....
The two forms are of the same namespace.
if within the namespace I do this:
namespace ABC{
ref class VPEForm;
public ref class OtherForm : public Form
{
the line:
ABCForm^ abcForm = (ABCForm^)Application::OpenForms["ABCForm"];
will compile without complaint. But then the line:
abcForm->ExecutePublicFunction();
I get:
use of undefined type : 'ABC:ABCForm'
Like it sees the 'ref class VPEForm' as the complete definition of
the class.
So what's the proper way to reference the other form and handle
the includes and namespace from another form?
This should be simple I know...
Thanks,
Steven