Im making the switch from VB.NET to C#, and Ive found it pretty easy so far, except for public variables.
In VB.NET, my startup class would be something like this...
In C#, I tried
But that gives me:
How do I go about doing it?
In VB.NET, my startup class would be something like this...
Code:
Public Class clsCore
Public O as clsOptions
...
End Class
In C#, I tried
Code:
public class clsCore
{
public clsOptions O;
...
}
But that gives me:
clsCore.cs(45): An object reference is required for the nonstatic field, method, or property Project.clsCore.O
How do I go about doing it?