Start working with Java

Hi everyone,
According to this page,
http://www.java2s.com/
There are heaps of technologies associated with Java.
As I am just a complete beginner, where do you think I should be starting with?
I am currently after a simple application with GUI, database
I think I should learn JSP afterwards, what is your opinion?
Thanks
Jack

Thanks guys for th replies.
Now I have the simple program working, so let's move on.
import java.awt.Button;
import java.awt.Color;
import java.awt.BorderLayout;
import java.awt.TextField;
import java.awt.Frame;
import java.awt.Font;
import java.awt.Label;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.WindowListener;
import java.awt.event.WindowEvent;
import java.awt.event.WindowAdapter;
import java.awt.event.FocusEvent;
import java.awt.event.FocusAdapter;
import java.awt.event.KeyAdapter;
import java.awt.event.KeyEvent;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
class Quotation
String QuotationID;
String QuotationType;
Quotation()
String FindByQuotationNo(String Type)
if (Type == "Test") {
return "Q08011132";
return "Error";
public class TestSwing extends Frame
Button post = new Button("Find");
Label mouseLabel = new Label("");
Quotation quo = new Quotation();
TestSwing(String title)
super(title);
super.setSize(500,400);
mouseLabel.setFont(new Font("Arial", Font.BOLD, 20));
mouseLabel.setBackground(Color.PINK);
super.add(post, BorderLayout.NORTH);
super.addWindowListener(new MyWindowListener());
super.add(mouseLabel, BorderLayout.CENTER);
mouseLabel.addMouseListener(new MyMouseAdapter(mouseLabel));
public static void main(String[] args)
TestSwing demo = new TestSwing("Hello World");
demo.setVisible(true);
String QuoType = quo.FindByQuotationNo ("Test");
class MyAction implements ActionListener
private String name = null;
MyAction(String name)
this.name = name;
public void actionPerformed(ActionEvent e)
class MyWindowListener extends WindowAdapter
public void windowClosing(WindowEvent e)
System.exit(0);
class MyMouseAdapter extends MouseAdapter
private Label label = null;
MyMouseAdapter(Label label)
this.label = label;
public void mouseClicked(MouseEvent e)
int x = e.getX();
int y = e.getY();
String key = null;
if (e.getButton() == e.BUTTON1)
key = "left key";
else if (e.getButton() == e.BUTTON3)
key = "right key";
label.setText ("X-" + x + "Y-" + y + "," +key);
With the above snippet, I wonder how can you connect "FindByQuotationType" to the main class
///// Error
C:\JavaTest>javac TestSwing.java
TestSwing.java:72: non-static variable quo cannot be referenced from a static co
ntext
String QuoType = quo.FindByQuotationNo ("Test");
^
1 error

Similar Messages

  • How i can start working with Java?

    Right now i am having only 8 months of exp in ABAP. can any one help me out to start working with Java specially for Netweaver Purpose

    It is great if you can get yourself familiar with java syntax, as is the case with any new langauage. However, the worst thing you can do is just code java in a top down approach. If you are not familiarizing yourself with OO concepts and best practices, then you are going to miss two important benefits that you will get from using OO programming - Reusability and flexibility in the frameworks that you develop (leveraging design patterns).
    These benefits will also be directly obtainable when you use ABAP objects.
    I am working in the opposite direction at the moment. I have some java experience, and I am starting to learn ABAP. I have used ABAP objects in my first project, and it was actually much better than I thought it would to be.
    Java and OO programming will be an ongoing learning experience. You will not be an expert for quite some time. I do not consider myself to be an expert by any means, and I've be studying OO and java for a few years.
    There is a fantastic book that explains OO concepts clearly, in much easier terms than the Gof "Design Patterns" book:
    Java Design: Objects, UML, and Process by Kirk Knoernschild
    You can read a few chapters at www.kirkk.com. (Use the JOUP link).
    Hope this helps you.
    - Brendan

  • Applets not working with Java 1.7.0_51 in MII 14.0 SP4 Patch 5

    Hi,
    I'm currently evaluating the migration of our MII 12.0 developments to MII 14.
    But I'm running in several issues just trying to use simple things like a SQL query template with an iGrid Display template in test mode.
    Used versions are: MII 14.0 SP4 Patch 5 and on client side the latest Mozilla Firefox with Java 1.7.0_51
    At first I always get a java security warning when the applet is being loaded about unsigned applications.
    At second the applet itself is not running. It always shows "No data available" and the java console shows the following errors (iResult is the id of the applet):
    iResult [ERROR] - Couldn't set query template: No Query Defined
    iResult [ERROR] - Couldn't set display template: null
    iResult [ERROR] - Couldn't set display template: null
    Is this perhaps a general problem, that the MII applets are not working with Java 1.7.x versions?
    If I call the same MII page from a client with Java 1.6.x it is working without errors.
    Do you have some suggestions for me?
    Regards Timo

    please clear your JAVA Cache. that should solve the JRE issue. thanks

  • Mapping editor not working with Java 5 classes

    I have a small protoype web service which I wrote using Tomcat/Axis/Spring/Hibernate and using EJB3 annotations for the mappings. I want to port the persistence layer to Toplink.
    I installed Toplink 9.0.4.1 and added the toplink libraries to my project and implemented the DAO and the spring bean defs.
    I opened the mapping editor and created a project. When I try to add classes to it for mapping I get an error that it can't find the classes (even though I selected them from the chooser). I figured it might be that they were compiled with Java 5, so I switched the JRE_HOME in setenv.cmd to my Java 5 JRE. Now I can import the classes and see the attributes but when I click on any of them in the Navigator panel, the editor panel remains blank. If I now try to save, I get:
    java.lang.NullPointerException
         at oracle.toplink.workbench.ui.tools.CheckListModel.getRowCount(CheckListModel.java:119)
         at javax.swing.JTable.checkLeadAnchor(JTable.java:2949)
         at javax.swing.JTable.tableChanged(JTable.java:2993)
         at javax.swing.JTable.setModel(JTable.java:2827)
         at oracle.toplink.workbench.ui.tools.CheckList.initialize(CheckList.java:47)
         at oracle.toplink.workbench.ui.tools.CheckList.<init>(CheckList.java:26)
    It seems that the mapping workbench doesnt work with Java 5. What should I do?

    Ah, I see. I saw another post here stating that must use 10.1.3.

  • SGD4.6 can't work with Java update7.51

    SGD4.6 can't work with Java latest version update 7.51. The webtop keeps showing "loading", is there any patch for this issue?
    When Java released update 7.21, it also can't work with SGD4.6, then Oracle fixed it by updating a patch, so how about this problem?

    Have a look at this Thread:
    https://community.oracle.com/thread/2614978

  • Just Starting out with java packages

    Hello,
    I'm a beginner and I'm starting out with java packages.
    I wrote two simple .java files, one test program and one containing a simple class.
    Both files are compiling without errors but When I run the program I get an error NoClassDeffoundError.
    I use the import <package> statement And I think I'm using the CLASSPATH variable correctly.
    SET CLASSPATH=d:\nopol
    path for the .java containing the test class is:
    d:\nopol\utilities \myapp.
    In the test file I use "import utilities.myapp.*.
    I would be very happy if anyone could help me
    Thanks beforehand
    Nopol.

    The test file should be in d:\nopol, if it's not a part of your package utilities.myapp. Everything should be compiled from d:\nopol, the test class with "javac ClassName.java" and the class in the package with "javac utilities/myapp/ClassName.java".
    Your classpath seems fine for now, though. But yes, do add the period there, otherwise you could run into problems later.

  • How to start working with iReport?

    Hi All,
    I'm just decide to use iReport for create report on Web but I don't know
    How to start working with iReport , What program I should to install , How
    to config any system files and set property .
    Please advice me for work with IReport.
    Thank you

    Hi,
    best hint to give is to start interviewing the product owner
    http://ireport.sourceforge.net/cap3.html
    Note that this is an open source project. Once you know which libraries you need, create a project in JDeveloper and double click on the project node. There is a Library node that allows you to import libraries to be used in your code.
    Under Tools --> Manage Libraries you can configure JSP tag libraries if required
    Frank

  • How to start working with fresh hyperion essbase 11.1.2.2

    Hi Experts,
    I have installed and configured hyperion 11.1.2.2 with below component
    1.Essbase
    2.HFM
    3.HFR
    4.Weblogic
    5.Oracle HTTP Server
    Now I want to start working with hyperion Essbase but not getting a proper way to start from where, its totally different from 11.1.3 which I used previously,
    So please help me which services to start with sequence and how to login into Essbsae console/studio to create new database with steps
    Thanks in advance

    If you want to use the standalone clients then you will need to install them separately, all the clients are available in the clients package which can be downloaded.
    It is also possible to use the EAS web console but the port you connect will depend on how you have configured the system, for example
    EAS deployed to own managed server - http://<servername>:10080/easconsole/console.html
    EAS deployed to one managed server - http://<servername>:9000/easconsole/console.html
    or you can use the http server port 19000, 9000 depending on the http server deployed.
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • When is Apple going to start working with ADOBE and let us enjoy some videos and other things on our beloved iPads and iPhones?

    When is Apple going to start working with ADOBE and let us enjoy some videos and other things on our beloved iPads and iPhones?

    How totally clueless can one be?
    Apparently not more than you.
    Adobe has given up on mobile flash for any device. They announced this a while ago.
    They admitted mobile flash is a disaster and are jumping on the HTML 5 bandwagon.
    Adobe has moved on, why can't you?
    http://www.technobuffalo.com/mobile-devices/adobe-announces-the-end-of-flash-pla yer-for-mobile-devices/
    http://latimesblogs.latimes.com/technology/2011/11/adobe-to-end-mobile-flash-plu g-in-development.html

  • Bugged audio playback? When I start working with more than 1 audio track.

    Hi!
    I have been using premiere elements 12 for editing FullHD videos.
    Brand new for me just bought it like 2 weeks ago.
    Now during the last couple weeks I have had this MAJOR proglem with editing the audio.
    This problem is headache and turns my simple editing into almost impossibilites.
    I have had this problem with all my projects. _ALL_
    Usually the problem seems to appear when I want to start working with several audio tracks.
    At somepoint my projects just get ruined, I simply cannot hear the audio tracks.
    The audio starts to disapear randomly from all the audio tracks.
    It is not only playback problem. When I exported the video, the audio was partly missing, same as the project.
    I have tried to look help on forums and search all what I could find, but havent been able to solve this.
    Small fix has slightly helped:
    I export audio to single track and bring it back to project. This works but I still usually have more editing to do.
    I simply cannot understand why the playback disapears, I fear it is a bug.
    I found lot of earlier version problems on people with similar type of problems, but no help for this version of program.
    To solve the matter I have changed my audio setting in PE12.
    Tried Premiere Elements WDM Sound and ASIO4ALL V2, but same problem on both.
    I have looked up that my audio playback device and PE12 matches, and are not muted, and volumes maxed.
    I have deleted my C:\ appdata\roaming\adobe  premiere elements & premiere elements 12 folder preferences.. not helping..
    I press the update pretty much everyday hoping for new version.. But yes, program keeps telling me its the latest.
    I usually only work with 3 audio track maxinum. And I am doing really the most basic stuff here..
    I have set all my audios to foreground and it has given me best results, but it does not seem to take the problem away as at somepoint randomly my audio playback is missing again, randomly across the playback.
    Please anyone? I am feeling hopeless here.
    Info on my computer:
    Operating system: Win7
    Processor: AMD Phenom(tm) x4 955 processor 3.20 GHz
    memory (RAM): 4GB
    system: 64bit
    <moved from downloading, installing, setting up forum by mod- kglad>
    Message was edited by: kglad

    First of all, thank you for replying my message!
    I will go and try to answer best I can.
    Source media properties:
    Progressive frame rate, I record this from a game.
    Recording program: dxtory
    codec: Lagarith Lossless codec
    Format: avi
    Frame width: 1920
    Frame height: 1080
    Data rate: 1990656kbps
    total bit rate 1992192kbps
    Frame rate 30/frames/seccond
    Audio of video properties:
    Codec: PCM
    Format: 16bit, stereo
    Bit rate: 1536kbps
    Channels: 2(stereo)
    Audio sample rate 48 kHz
    In addition to that I use wav files for music and narrate
    Music files sizes 20-50mb
    bit rate: ~1411kbps
    In total sizes of audio involved is usually something like 300mb
    What are you or the program setting as the project preset in the new project dialog. See Edit Menu/Project Settings/General and its Editing Mode, Timebase, and Frame Size readings.
    I opened new project and this is what i got:
    Editing mode: HD 1080i
    Timebase: 25,00 frames/second
    Frame size: 1920 x1080
    Audio is 48000 Hz
    (I dont know how to change these, btw. Program don't seem to let me change editing mode.
    I also looked up my most recent project and found these settings:
    Editing Mode: DSLR
    Timebase: 30,00 frames/second
    Frame size: 1920 x1080
    ..and same audio settings
    Do the problems persist if you start a new project? Do you find the audio problems develop when the Timeline content is fairly well developed or can the problems occur when there a minimal amount of content of those tracks? Let us look at the size and duration of this project.
    Yes, I have had this problem with all my projects. Sometimes it goes away tho, just enough for me to work bit more. My work progress usually starts by clipping the video material, like 1h material to 8minutes in clips. After that I want to work with audio tracks, and here problems start! When I start working with more than 1 track, so the problem is at later stage. To fix the problem a small fix I have used, I export audio like music and effects tracks together to 1 wav and bring it back. After that, I start working with narrate track. To describe the problem with audio:
    Audio Randomly starts to disapear when I playback, and can also be gone if I export the video out.
    My source videos total size are usually within 80Gb max limit and audio edit material 300mb total.
    In my last project my biggest source video was 47GB and leingth of 1h 4m, in addition to that I had 3 smaller videos, sizes of 1GB, 1,54GB and 300MB.
    Is there any evidence that you are accidentially moving the audio track rubberband to alter the audio volume. That rubberband is the orange line that runs horizontally through the middle of the audio clip when you are looking at the wave form display style of that audio track. The rubberband represents audio volume.
    No, audio volumes might have been adjusted in my tracks but they are present. The problem is usually like ~2-5seconds, a random audio track can be heard (like music or narrate) or just no sounds at all. This makes it very difficult to work with the audio. Also I gotta say that this problem starts by simply having the 2-3 audio tracks.. In my recent project the only adjustment I used to edit the audio was fade in/out.
    I don't have any other audio problems with any other programs.
    I am more than happy to provide more information if needed. I hope this information helps.
    In addition I can say that when I close Adobe Premiere Elements 12, it crashes. No idea why.
    I have also looked up my firewall settings, anything involved adobe and premiere..
    In addition some effects like HD text templates make "Adobe Media Core CS6" crash. I tend to just not use em, or if I need em, I add em at end of the edits.
    I hope this helps, I would really like to solve this problem.
    Thank you alot for taking the time to answer! I welcome anyone to help mee too! Please giev links to similar problems too. Thank you everybody!

  • Start working with adobe premiere pro cs 5.5 in german

    It doensn' make fun to start working with adobe pro cs 5.5. I dont find do kuse the programm window. I cut one scene and after that I did'nt hear the audio.

    Are you sure you want to start in German.
    Most tutorials are in English.
    Best place to start is with Adobe tutorials:
    Learn Premiere Pro CS5 & CS5.5 | Adobe TV 

  • SDM still not working with Java v6u15

    I keep waiting for Java to work some day with their updates on Cisco SDM. Update 14 at least allowed SDM to open. But the new update 15 still hasn't passed the test of clicking on the Configure button and then the Additional Task button. It just doesn't do anything. If it is something that Cisco can fix, please be aware.
    Thanks,
    .. Jim ..

    Hi Jim, you need to downgrade the JAVA version on the computer you want to use SDM.
    SDM does not support java after: 6u3.
    Cisco SDM requires Sun Java Runtime Environment (JRE). The following versions are supported:
    •JRE 1.5_09
    •JRE1.4.2_08
    •JRE 1.5.0_06
    •JRE 1.5.0_07
    •JRE 1.6.0_02
    •JRE 1.6.0_03
    As per the release notes.
    http://www.cisco.com/en/US/docs/routers/access/cisco_router_and_security_device_manager/software/release/notes/SDMr25.html
    This will resolve your issue.
    Cisco does not plan to fix this as SDM is end of life.
    The product that replaces SDM is CCP: Cisco Configuration Professional, that one works with JAva 6 update 14, but it's a different product. It's also a freeware you can download from our website.

  • Can "scrollmouses" work with java scrollbars

    Hi,
    These days many mouses have a third "button" (between the two usual buttons) for scrolling. So my question: Is it possible to get this scroll-button to work with java scrollbars?
    -Ohto

    I haven't done anything with it myself, but mouse wheel support was added in 1.4. Check out the java.awt.event.MouseWheelEvent class.

  • Who works with java?

    A friend of mine was telling me how just about every app the isp he works for is designing lately, they've been doing in java. Now this got me curious because I havent' seen much on java for the past year. I'm just curious, if you work with java, what kind of apps do you tend to create with it?

    Java is pretty much the top language for server side applications, I think because of its high quality threading (it can serve many clients easily). It also seems to be the language of choice for all business applications lately. But that's just because some idiots in a suit heard the name 'java' and decided it was cool, IMNSHO.
    You probably haven't heard much about it because a) Its not overly popular for desktop programs yet b) the apps that use it just use it without bragging about it and c) its not overly popular in open source. But it seems to be getting bigger.
    To answer your question about what kind of apps I personally create, check the signature.
    Dusty

  • Is oracle ebs work with java version 7.51 ?

    Hi,
    is oracle ebs work with java version 7.51 ?
    Thanks

    Findy Nurtantio wrote:
    Hi,
    is oracle ebs work with java version 7.51 ?
    Thanks
    Yes, Java JRE 1.7.0_51 is certified with Oracle E-Business Suite -- https://blogs.oracle.com/stevenChan/entry/java_jre_1_7_08
    Thanks,
    Hussein

Maybe you are looking for

  • Bridge CS4 - Lost all file associations - On 2 computers

    I run Photoshop CS4 on my desktop and notebook, Windows XP Pro. I have lost all my file associations with bridge CS4.  If I clicked on a .jpg MS paint would start up.  It use to work before no problem.  If I reset, it does nothing.  This is happening

  • My bookmarks have disappeared and my backups will not import.

    I opened Firefox today and all my bookmarks are gone, as well as my browsing history. I have not updated anything or changed the program in any way since I last saw my bookmarks. I tried to import any of my backup files, and not one of them will work

  • Request status changed!

    Hi, in the manage tab of data target when i see the status of the request it is yellow and added records and transferred records has adifference of almost 40000. but when i click monitor button, it goes to the monitor screen with following msg      "

  • Applet can not read from servlet because of java.io.EOFException

    Hi all, i try to communicate my applet with a servlet. i examine lots of codes from internet and i did lots of things to get a working sample but i couldn't sucess on this work for 2 days so if anyone can help me i will be very happy. Anyway, here is

  • Saving Media Kind, Position & Shuffling in ID3 Metadata for MP3 Audiobooks?

    Hello, I have a problem saving "media kind" - audioboks as file metadata independent of iTunes. I recently purchased an iPhone however I am pretty apathetic to iTunes - I use it as my only media player at the moment because of the iPhone, however I w