I'm coding in Visual C++ .NET. I have a managed class(FORM1) that displays a form. .NET framework objects can only be define within function scope. I have a main program that creates an instance of FORM1. I have some callbacks in main that need to access the functions in FORM1, but it can't since FORM1 is undeclared outside function main. What can I do to make FORM1 a 'global' object?

Copying to .NET forum.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.