Newby needs help!!

I am new to Java and I am trying to write a basic application for a class but I can't get it to work. The application is a payroll program that includes the employee name, hourly wage, hours worked, and lastly net pay. I can't get the code to compile wihtout kicking back errors. Someone please help!
Thanks!

I can't get the code to compile
wihtout kicking back errors. That's normal. It's a rare thing when a program is written without any syntax errors on the first try. Don't let it discourage you. Just fix the errors that the compiler tells you about. If you don't understand an error or don't know how to fix it, you can post here, but when you do so be sure to quote the full error message and the code that it refers to.

Similar Messages

  • Nokia 8800 - Complete Newby Needs Help !!

    Hi All
    Im a complete newby to this tech lark so could do with some help!
    Basically ive just got a nokia 8800 phone & its got nothing on it so I want to transfer some tunes, vids etc onto it.
    Firstly ive installed the nokia pc suite & updated it on my pc but then relaised that the phone doesnt have a cable dock to connect to the pc !
    Ive ordered a bluetooth dongle like this: http://cgi.ebay.co.uk/BLUETOOTH-DONGLE-FOR-NOKIA-N-GAGE-8800-6280-6230i-7373_W0QQitemZ220133688184QQ...
    Do i need to install the software that come with the dongle? i.e. drivers & blue soleil?
    When ive got passed this bit i assume pc suite will see the phone then?
    Any step by step help would be appreciated.
    Many thanks
    Jason

    Bluetooth and Windows is a bít tricky combination, because Windows XP (which I assume you have) has an inuildt Bluetooth driver software that works with many Bluetooth USB tcks tc. but not all.
    YOu might have a Bluetooth that requires the Bluesoleil and the bluetooth conflicts in PC have been well documented in this board and everywhere else.
    But you should try:
    Install the CD first (if you have already put the bluetooth dongle to your PC without intalling the cd first you maybe in trouble already and it is a bit too lenghtly to hrlp, but google for xp bluetooth bluesoleil problem and oyu will find help.
    However, if you have not yet put the bluetooth stick to you pc, put it there after you have installed the cd.
    Then open PC suite and get connected and activate both phone bluetooth and pc and follow get connected wizard instructions

  • Newby needs help please

    Hi
    Have just got my Blackberry 8900 yesterday, can text and call people but am having a few problems elswhere.
    I have connected the 8900 to the Desktop Manager and updated. I have no maps, how can I get them.
    Also I have outlook 2003 on my home laptop, I want to be able to recieve these emails to my 8900 and also other email address, I guess maybe Hotmail etc. Can I have all these to my 8900?

    To download Maps you can go to www.blackberry.com/maps , but you need the Blackberry Data Plan ( i wrote this for you in your other thread)
    And after you can setup the mails on the device, but the mails are not synched with Desktop Manager, you have the setup in outlook and in the Blackberry Device.
    To sync mails, you need any exchange server. 
    If I help you with any inquire, thank you for click kudos in my post.
    If your issue has been solved, please mark the post was solved.

  • Newby Needs Help Connecting to Oracle Database

    I'm very very new to java. I'm trying to write a program to connect to and read some fields in an oracle table. I'm having problems and am not sure how to correct it. I downloaded and installed the oracle thin driver. I'm using Eclipse 3.3 and JRE 1.6. This is my code:
    import java.sql.*;
    public class One {
         public static void main(String[] args) {
              try {
                   DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
                   System.out.println("let's connect");
                   Connection conn=DriverManager.getConnection(
              "jdbc:oracle:thin:@a571p05.pt.com:1521:orap1","username","password");
                        System.out.println("I'm connected");
                        Statement stmt=conn.createStatement();
                        ResultSet rset=stmt.executeQuery(
                             "select CUSTNUM,CUST_LNAME from TBL.CUSTOMER where " + "CUSTNUM=\"12345678900\"");
                   System.out.println("Result set?");
                   while (rset.next())
                        System.out.println(rset.getString(1)); //Print col 1
                   stmt.close();
              catch(Exception x) {
                   System.out.println("Unable to connect!");
              System.exit(0);
    If I just run it, this is the output:
    let's connect
    I'm connected
    Unable to connect!
    So, it looks like it may be connecting, at least it runs the line that establishes the connection then the next line which prints a comment. However, it seems to fail at some point thereafter. I've tried debugging it and as far as I can tell, it's erroring out on thie line:
    DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    with this stack trace:
    Thread [main] (Suspended)     
         ClassNotFoundException(Throwable).<init>(String, Throwable) line: 217     
         ClassNotFoundException(Exception).<init>(String, Throwable) line: not available     
         ClassNotFoundException.<init>(String) line: not available     
         ClassLoader.findBootstrapClass(String) line: not available [native method]     
         Launcher$ExtClassLoader(ClassLoader).findBootstrapClass0(String) line: not available     
         Launcher$ExtClassLoader(ClassLoader).loadClass(String, boolean) line: not available     
         Launcher$AppClassLoader(ClassLoader).loadClass(String, boolean) line: not available     
         Launcher$AppClassLoader.loadClass(String, boolean) line: not available     
         Launcher$AppClassLoader(ClassLoader).loadClass(String) line: not available     
         Launcher$AppClassLoader(ClassLoader).loadClassInternal(String) line: not available     
         One.main(String[]) line: 8     
    I checked the project properties\java build path and I have JDBC_THIN_DRIVER and JRE_SYSTEM_LIBRARY listed there. Do I need something else? I'm not quite sure what I'm missing or what the errors are telling me. Any help, or pointers are appreciated. Thanks much!

    I would write that class more like this, assuming that customer ID is a String:
    import java.sql.*;
    public class One
       private static final String DEFAULT_DRIVER = "com.oracle.jdbc.Driver";
       private static final String DEFAULT_URL = "jdbc:oracle:thin:@a571p05.pt.com:1521:orap1";
       private static final String DEFAULT_USERNAME = "username";
       private static final String DEFAULT_PASSWORD = "password";
       private static final String SQL = "select CUSTNUM,CUST_LNAME from TBL.CUSTOMER where CUSTNUM=?";
       private static final String DEFAULT_CUSTOMER_ID = "12345678900";
       public static void main(String[] args)
          Connection conn = null;
          PreparedStatement stmt = null;
          ResultSet rset = null;
          try
             Class.forName(DEFAULT_DRIVER);
             conn = DriverManager.getConnection(DEFAULT_URL, DEFAULT_USERNAME, DEFAULT_PASSWORD);
             stmt = conn.prepareStatement(SQL);
             String customerId = ((args.length > 0) ? args[0] : DEFAULT_CUSTOMER_ID);
             stmt.setString(1, customerId);
             rset = stmt.executeQuery();
             while (rset.next())
                System.out.println(rset.getString(1));
          catch (Exception x)
             x.printStackTrace();
          finally
             close(rset);
             close(stmt);
             close(conn);
       private static void close(Connection conn)
          try
             if (conn != null)
                conn.close();
          catch (SQLException e)
             e.printStackTrace();
       private static void close(Statement stmt)
          try
             if (stmt != null)
                stmt.close();
          catch (SQLException e)
             e.printStackTrace();
       private static void close(ResultSet rset)
          try
             if (rset != null)
                rset.close();
          catch (SQLException e)
             e.printStackTrace();
    }%

  • Newby Needs help with mapping an illusion

    Attached is a picture of an illusion that I would like to be able to reproduce with different shapes. I have tried using several different programs including Photo shop and some cad programs. The problem is when I create the illusion the lines around the edge do not stay aligned  with the illusion (see illusion 2 as how they should be).
    Any help would be most appreciated.
    Thanks
    Larry

    Hello Larry,
    Here is what I do:
    Then you can add more squares and everything will be straight.
    And also you can play with several shapes:
    I hope this helps!

  • Newby need help with pop up banner

    Hei
    I'm a young designer at a company. I havn't used java at all but i was assigned to make a moving banner. It has to move side by side horizontally and the other problem i'm facing is that the background has to be transparent.
    I have googled for two days now and have made a very basic website (four pages), could someone please walk me trough the process. I have found a lot of code have found a lot of tutorials but can't figure out where to paste the code. I have made a website to a free isp to test my new knowledge.
    -i have to make a window.open method
    -make the background transparent (is this process easier in flash) ?
    -make it move side-to-side
    I could help out with some disaign (wallpapers, banners, logos) i'm not skilled with code soo it takes my a while to understand.
    I'm ready to learn java but now i havn't got much time.
    I'm learning the basics right now but my assigment is much more difficult.
    Please help

    It sounds like you're working with Javascript, and not Java.
    Also, are you trying to make a webpage with a transparent background?
    One last thing, this works pretty well for "moving banners".
    <marquee>I am a moving banner.  Feel free to replace me with an img tag.</marquee>Edited by: codingMonkey on 2008/12/04 12:21

  • JAVA newby needs help - second try

    Sorry I goofed up the first post!!
    I am trying to learn JAVA on my own and am stuck on using random numbers. My grandson is having problems in math (he is 7) and I want to create a math quiz that will generate two numbers between 0 and 10 and ask him for the correct answer. I understand the JOptionPane and how to display what I wan it to say (easy) but I do not know how to make the result of the sum of the two randoms be the required user (my grandson) input.
    Here is what I have (don't laugh it's a mess):
    /* ROMAD, January 21, 2007
    * Trying to write a Java program for
    * my grandson so he can practice and
    * learn how to multiply using two integer numbers*/
    package mathTest;
    import javax.swing.JOptionPane;
    import java.util.*;
    public class MathTest_1 {
        public static void main(String[] args) {
            Random randomNumbers = new Random();
            // pick random number values between 0 and 10
            int number1 = 1 + randomNumbers.nextInt(10); // first random number
            int number2 = 1 + randomNumbers.nextInt(10); // second random number
            String response;
            response = JOptionPane.showInputDialog("Enter the maximum number");
         // place random number values here and ask for correct number
            System.out.printf("How much is %d times %d\n", number1, number2);
            // ask player what is the answer
            response = JOptionPane.showInputDialog(null,"How much is %d * %d");
            if (response == null)
                JOptionPane.showMessageDialog(null,
                                              "You must enter a value first");
            else if (response.equals(""))
                JOptionPane.showMessageDialog(null, "Please try again");
                JOptionPane.showMessageDialog(null,
                                              "Great! Would you like to play again?");
            System.exit(0);
    }

    The JOptionPane returns user input as a String. Use Integer.parseInt() to parse the string answer to an int value, which you can then compare as needed.
    Here's an example: Converting Strings to Numbers
    ~

  • JAVA newby needs help

    I am trying to learn JAVA on my own and am stuck on using random numbers. My grandson is having problems in math (he is 7) and I want to create a math quiz that will generate two numbers between 0 and 10 and ask him for the correct answer. I understand the JOptionPane and how to display what I wan it to say (easy) but I do not know how to make the result of the sum of the two randoms be the required user (my grandson) input.
    Here is what I have (don't laugh it's a mess):
    /* ROMAD, January 21, 2007
    * Trying to write a Java program for
    * my grandson so he can practice and
    * learn how to multiply using two integer numbers*/
    package mathTest;
    import javax.swing.JOptionPane;
    import java.util.*;
    public class MathTest_1 {
        public static void main(String[] args) {
            Random randomNumbers = new Random();
            // pick random number values between 0 and 10
            int number1 = 1 + randomNumbers.nextInt(10); // first random number
            int number2 = 1 + randomNumbers.nextInt(10); // second random number
            String response;
            response = JOptionPane.showInputDialog("Enter the maximum number");
         // place random number values here and ask for correct number
            System.out.printf("How much is %d times %d\n", number1, number2);
            // ask player what is the answer
            response = JOptionPane.showInputDialog(null,"How much is %d * %d");
            if (response == null)
                JOptionPane.showMessageDialog(null,
                                              "You must enter a value first");
            else if (response.equals(""))
                JOptionPane.showMessageDialog(null, "Please try again");
                JOptionPane.showMessageDialog(null,
                                              "Great! Would you like to play again?");
            System.exit(0);
    }

    > Done! I goofed it up but sent out another formatted correctly
    It's typically considered good form to continue in the same thread rather than starting a new one. At the very least, you'll want to provide a link to the new thread (as in reply #3), so people aren't answering your question in two different threads.
    ~

  • Need help to develop Pythagoras theorem-

    Hi i need help to develop proofs 2,3,4
    of pythagoras theorems in java as demonstrations
    These are applets can anyone help me with it or give me an idea of how to go about developing it -
    the site is the following
    http://www.uni-koeln.de/ew-fak/Mathe/Projekte/VisuPro/pythagoras/pythagoras.html
    then double click on the screen to make it start

    Pardon my ASCII art, but I've always liked the following, simple, geometric proof:
         a                   b
    ---------------------------------------+
    |       |                                |
    a|   I   |              II                |
    |       |                                |
    ---------------------------------------+
    |       |                                |
    |       |                                |
    |       |                                |
    |       |                                |
    |       |                                |
    b|  IV   |              III               |
    |       |                                |
    |       |                                |
    |       |                                |
    |       |                                |
    |       |                                |
    |       |                                |
    ---------------------------------------+It almost goes without saying that I+II+III+IV == (a+b)^2, and II == IV == a*b,
    I == a*a and III == b*b, showing that (a+b)^2 == a^2+a*b+a*b+b^2.
    I hope the following sketch makes sense, stand back, ASCII art alert again:     a                   b
    ---------------------------------------+
    |               .             VI         |
    |     .                 .                |a
    | V                               .      |
    |                                        +
    |                                        |
    |   .                                    |
    b|                                     .  |
    |                                        |
    |                  IX                    |
    | .                                      |
    |                                    .   |b
    |                                        |
    +                                        |
    |      .                                 |
    a|               .                  . VII |
    |  VIII                   .              |
    ---------------------------------------+
                     a                    bThe total area equals (a+b)^2 again and equals the sum of the smaller areas:
    (a+b)^2 == V+VI+VII+VIII+IX. Let area IX be c^2 for whatever c may be.
    V+VII == VI+VIII == a*b, so a^2+b^2+2*ab= c^2+2*a*b; IOW a^2+b^2 == c^2
    Given this fundamental result, the others can easily be derived from this one,
    or did I answer a question you didn't ask?
    kind regards,
    Jos

  • I need help to find and open a job app that I exported, was able to fill out and sign and saved and now can't open it? What did I do wrong?

    I need help to find and open a job app that I exported, was able to fill out and sign and saved and now can't open it? What did I do wrong?

    What file format did you export it to?

  • Need help to open audios attached in a PDF file

    Hello
    I just need help. I have ordered a reviewer online that has audios and texts in a pdf file. I was told to download the latest adobe reader on my computer. I have done the same thing on my ipad mini. I am not so technical with regards to these things. Therefore I need help. I can access the audios on my computer but not on my ipad.
    I want to listen to audios with scripts or texts on them so i can listen to them when i am on the go. I was also informed that these files should work in any device. How come the audios doesnt work on my ipad.
    Please help me on what to do.
    Thanks

    Audio and video are not currently support on Adobe Reader. :-<
    You need to buy a PDF reader that supports them. My suggestion is PDF Expert from Readdle ($US 9.99)

  • Need help to open and look for file by name

    Hi,
            Im needing help to open a folder and look for a file (.txt) on this directory by his name ... The user ll type the partial name of file , and i need look for this file on the folder , and delete it ....
    How can i look for the file by his name ?
    Thx =)

    Hi ,
        Sry ,, let me explain again ... I ll set the name of the files in the follow order ... Name_Serial_date_chanel.sxc ..
    The user ll type the serial that he wants delete ...
    I already figured out what i need guys .. thx for the help ^^
    I used List Directory on advanced IO , to list all .. the Name is the same for all ... then i used Name_ concateneted with Serial(typed)* .. this command serial* ll list all serials equal the typed , in my case , ll exist only one , cuz its a count this serial .Then i pass the path to the delete , and its done !
    Thx ^^

  • I need help, my ipod touch is not recognized by windows as a harddisk

    i need help, my ipod touch is not recognized by windows like a memory card or a harddisk.
    i would like to transfer the files from pc to my ipod touch without useing itunes.
    as i see theres some people here that theires ipod touch are recongnzed as a digitl camra, mine is reconzied as nothing, some help plz.
    Message was edited by: B0Om

    B0Om wrote:
    ok but i still dont understed, only my itnes recongnize my ipod, when i go to " my cumputer, it dosent show up there, not even as a digital camra
    Your Touch is working correctly. Currently, without unsupported third party hacks, the Touch has NO disc mode. It will only show up in iTunes.
    how do i put programes and games in my ipod touch
    Right now, you don't. The SDK is scheduled to be released in Feburary. Then developers will be able to write programs that will be loadable.

  • Weird error message need help..

    SO.. i havent updated my itunes in a while because i keep getting this weird message.. it comes up when im almost done installing the newest/newer versions of itunes. it says
    "the feature you are trying to use is on a network resource that is unavailable" "click ok to try again or enter an alternate path to a folder containing the installation package 'iTunes.msi' in the box below"
    now when ever i choose a file from the browse box it replies with this message "the file 'xxx' is not a valid installation package for the product iTunes. try to find the installation package iTunes.msi in a folder from which you can install iTunes."
    no idea need help thanks
    ~~~lake
    Message was edited by: DarkxFlamexCaster
    Message was edited by: DarkxFlamexCaster

    +it comes up when im almost done installing the newest/newer versions of itunes. it says+ +"the feature you are trying to use is on a network resource that is unavailable" "click ok to try again or enter an alternate path to a folder containing the installation package 'iTunes.msi' in the box below"+
    With that one, let's try the following procedure.
    First, head into your Add/Remove programs and uninstall your QuickTime. If it goes, good. If it doesn't, we'll just attend to it when we attend to iTunes.
    Next, download and install the Windows Installer CleanUp utility:
    Description of the Windows Installer CleanUp Utility
    Now launch Windows Installer CleanUp ("Start > All Programs > Windows Install Clean Up"), find any iTunes and/or QuickTime entries in the list of programs in CleanUp, select those entries, and click “remove”.
    Next, we'll manually remove any leftover iTunes or QuickTime program files:
    (1) Open Local Disk (C:) in Computer or whichever disk programs are installed on.
    (2) Open the Program Files folder.
    (3) Right-click the iTunes folder and select Delete and choose Yes when asked to confirm the deletion.
    (4) Right-click the QuickTime folder and select Delete and choose Yes when asked to confirm the deletion. (Note: This folder may have already been deleted if QuickTime was successfully removed using Add/Remove Programs earlier.)
    (5) Delete the QuickTime and QuicktimeVR files located in the C:\Windows\system32\ folder. Click Continue if Windows needs confirmation or permission to continue. (Note: These files may have already been deleted if QuickTime was successfully removed using Add/Remove Programs earlier.)
    (6) Right-click on the Recycle Bin and on the shortcut menu, click Empty Recycle Bin.
    (7) Restart your computer.
    Now try another iTunes install. Does it go through properly now?

  • I got new hard driver for my MacBook I don't have the cd but I do have flash drive that has the software I need help because when I turn on my laptop it shows me a file with question mark how can I install the software from the flash driver?

    I got new hard driver for my MacBook I don't have the cd but I do have flash drive that has the software I need help because when I turn on my laptop it shows me a file with question mark how can I install the software from the flash driver?

    Hold down the Option key while you boot your Mac. Then, it should show you a selection of devices. Click your flash drive and it will boot from that.

Maybe you are looking for

  • Populating the key figure in the Cube

    hi frineds,      I need to populated the custom key fiugre added by me in the cube using the update rule. But if i see the tables of the cube it is seperate for every dimension and key figure. how can i select the particular record from the key figur

  • New Mail Sound...  Wont let me change to sound I want.

    I downloaded a .wav file and want to change my new mail sound to that .wav sound. I can add it but when I get new mail it doesn't play it. Anybody know what the deal is?

  • Splitting using Java mapping

    Hi,     I am working on a file to IDOC scenario.In the input file am getting data for multiple idocs.The file structure is such that in the sender communication channel am not able to identify the recordsets and hence cannot set the number of records

  • Convert report writer to report painter

    Hi, Please advice how to convert report writer to report painter. I have used GR31 to create a report writer but I need to convert it to a report painter as in GRR3.

  • Display rows for empty and mesure values

    Hi, We are building live office objects charts on top of WEBI documents and facing an issue while refreshing the data in live office object for empty measure and empty dimension values. Charts are pointed to the data cells in the live office table an