I'm using NetBeans to write a Java Project. When I tell NetBeans to open the form as the Main Class it opens it like this:
http://dl.dropbox.com/u/12868212/Good.jpg
But I want to use a specific Main Class that I wrote, which calls the constractor of the aforementioned form and I get:
http://dl.dropbox.com/u/12868212/Bad.jpg
The constructor code:
public class Main {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
//Updating Global Variables Class:
GlobalVariables.Update_Global_Variables_From_Configuration_XML();
Form_StudentPresentation form_StudentPresentation =
new Form_StudentPresentation();
form_StudentPresentation.setVisible(true);
}
Can someone tell me what is wrong? How can i call the constractor in the main so that the form will look like the Good.jpg?
I think forms/frames created with Netbeans have look and feel code by default.
Check if the lookAndFeel setter is being called inside your class, or in a main inside your form.
You could also check if you have any look and feel specification as running arguments in your project settings.