Question:
Moving from .net to java. Please Help?
xbox786
2014-02-08 11:36:10 UTC
I have installed IntelliJ a month ago and still struggling with it. What is mainly holding me back is the GUI creation. I would like to rewrite the sample desktop apps I can easily write in C# in java. There are multiple things that I don't understand but I can't let them blocking my way. If anyone, preferably with both experience, can help me out, it would be great. I put my points below:

I learned C# in Visual Studio like 5 years ago. Back then, I didn't know what class is, what is a method or a function, what are the files involved. All I did is install the express edition from their site, started a new project as Windows Application Form, and the GUI is presented. I just dragged a label from the available components and change the Text property to "Hello World" and clicked run. That is how I created my first hello world program without even knowing that there it is a programming language and and there are codes involved.

Then I dragged a button and selected the MouseClick event. The coding window appeared providing me the opportunity to define what happens when the button is clicked. There I learned that this is what coding is. There I started my programming journey. I learned that all those labels and buttons are classes and each button I create is an object. I then attempted to create my own class and learned the concepts. I started creating UI components dynamically the same way I would create an object of any other classes. Today, after five years, I know how to create a simple mine sweeper game using multi threading and know how to interact with multiple forms using pointers to objects, but I learned all these one at a time in the correct order.

I am trying to use IntelliJ to create the same programs that I can easily create in VS in like 5 minutes. Below are something that I hated and don't understand why it is like that:

1) The first thing that blocked me is that I didn't have JDK installed. I had to at least go to a website to know where to install JDK from and how to make IntelliJ point to the correct JDK directory. This is not a big thing that I should be complaining about, but my point is why IntelliJ does not come in a package with JDK installed if this is an essential step?

2) Next, when I create a new project, it just showed me the project window with the necessary files. This means I have to know about the file structure and which files are responsible for what action to some extent.

3) Next, I had to create a GUI by going through an online tutorial. I like the Windows Form Application in VS because the GUI is presented at beginning ready for you to drag and drop. Isn't that how human brain thinks, first visualize how the app would look, then think how it will function? I do not remember going through any tutorials when working in VS.

4) I also hate how the tutorial for creating the hello world application teaches the concept of classes in order to make me create this simple newbie app. This is not a deal for me (I already know how class works), but if I were to teach programming to a newbie, am I suppose to teach him the concept of class before teaching him how to create simple functions or even simple for and while loops?

5) Why does a newbie program such as hello world will require a tutorial? I learned VS with Windows Form at first, then learned console. I didn't have to take any online help until I was stuck with multiple form interactions with object pointers, creating multiple threads, and using delegates. I automatically learned how classes works just by clicking Add Class and realizing that I can organize my functions there. Later of course, I was able to apply all the programming concepts such as static classes, inheriting class, information hiding, etc.

6) I wanted to create a simple moving button which I created in VS when I was first learning it. The first thing where I am stuck is the fact that IntelliJ use grid layout. In VS, I used the location property to smoothly move a button so that clicking it is harder (it has no use, but I want to create it just for fun). The grid layout (or any other layout) does not allow me to freely place UI objects anywhere I want. I use these capabilities to create a brick breaker game where I would create a Graphics circle object as a ball and make it bounce when it reaches the wall.

I know once I get a hang, I will stop using VS. But I need serious help just to get started.
Four answers:
JerryOfBorg
2014-02-08 12:04:51 UTC
Wow. I can tell you have a passion for what you are going through. I completely understand. I have a suggestion for you. You don't have to LEAVE anything in order to succeed. It really can all come together and form you as a programmer with broad skills.



If you really think that Java will pay off for you, then continue. But, before you spend too much time on that let me suggest another path which interestingly enough lies before you begging you to enter.



Take a real serious look at AngularJS. http://angularjs.org/



Then, get in contact with two guys who have straddled between Microsoft and other worlds for several years. Dan Wahlin http://weblogs.asp.net/dwahlin/ and John Papa. http://www.johnpapa.net/



If you write the them they will help you. Keep your comments short, they tend to skim.
Voice of Insanity
2014-02-08 13:09:09 UTC
Maybe you will get along better with Netbeans. Here is a tutorial explaining how to create a GUI.

https://netbeans.org/kb/docs/java/gui-functionality.html

And moving GUI elements seems to work fine there, I just tested it. I placed a button, double clicked it and typed in "jButton1.setLocation(100, 100);", then clicked on Run.

The button jumps to the new location after clicking it so it seems to be working despite the layout thing.
Anonymous
2014-02-08 12:02:08 UTC
Sun MicroSystems - JAVA Training - 9CD Set - [DDR]

VTC Complete Java Video Tutorials Courses

InfiniteSkills.Advanced.Java.Programming



Go through those. If you don't know what torrents are, then just pay for some overpriced college courses.
Judith
2016-03-10 03:06:07 UTC
Go with Java. It's so good MS attacked it's market with more crappy developer tools and still lost in terms of industry implementation. If you search the only end user solutions done with .NET are mediocre utilities and games by entry level developers.


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...