I tend to stay away from using modules at all; if you use a shared
(static, in C#) variable in a class, you can access it without needing an instance
of the class.
In Class1,
C#:
public static NWDSAConnStrings g_ConnStrings;
Then in Class2 you can either access it with
C#:
Class1.g_Connstrings
or add a using statement at the top
of the class like this:
C#:
using MyNamespaceName.Class1;
and then just simply access
'g_Connstrings' like you would as if it was in a module.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.