When you program in Java, you have a package, and in that package you put class files, where you write your logic, you have one main file, and you spread your code in the rest of the classes, for example, I have one class which I use only for static variables, like this
package com.mypackage.models;
public class MyConsts {
public static final boolean DEBUG = true;
// bla bla bla
}
and then, from whichever class I can call that variable like this
MyConsts.DEBUG
Now, how do you make more classes just like in Java, but in C# for a WPF application, currently I only have this, and I only write the code in Form1.cs
Aucun commentaire:
Enregistrer un commentaire