Results 1 to 4 of 4
  1. #1
    bdl
    bdl is offline Member
    Join Date
    Mar 2012
    Posts
    2
    Rep Power
    0

    Default netbeans budget code help?

    I am trying to create code in NetBeans for a budget that will take my inputs from keyboard for classes initial amount, debt, asset(if you get money during the month), a description of the debt. I want to see a printout of the amount left in budget or balance, amount spent, and the descriptions of debts. I am lost and it's killing me. I tried to look for example code to implement, but no joy. HELP!

  2. #2
    KevinWorkman's Avatar
    KevinWorkman is offline Crazy Cat Lady
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    3,701
    Rep Power
    8

    Default Re: netbeans budget code help?

    What exactly have you tried? Where exactly are you stuck? Throw together an SSCCE that demonstrates exactly what you're talking about, and we'll go from there.
    How to Ask Questions the Smart Way
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

  3. #3
    bdl
    bdl is offline Member
    Join Date
    Mar 2012
    Posts
    2
    Rep Power
    0

    Default Re: netbeans budget code help?

    I have got the following code to work, but, I need to be able to take what was added the last time it was run in order to keep a tally on what was done in the past(I hope this makes sense) I am proud of what I have so far, I am not a computer guy what so ever. Thanks for your help.
    /*
    * To change this template, choose Tools | Templates
    * and open the template in the editor.
    */
    package budget;

    import java.io.* ;

    public class Budget {

    public static void main(String args[])
    {
    InputStreamReader istream = new InputStreamReader(System.in) ;
    BufferedReader bufRead = new BufferedReader(istream) ;

    System.out.println("$$$ Keeping Track Of Your $400.00 Monthly Budget $$$");
    try {
    System.out.println("Enter The Amount Of New Asset(s): ie 123.45 ");
    String newAsset = bufRead.readLine();

    System.out.println("Enter The Total Amount Of Your Expense(s): ie 123.45");
    String expense = bufRead.readLine();

    System.out.println("Enter Description Of Expense: ");
    String description = bufRead.readLine();


    double newAsset1 = Double.parseDouble(newAsset);
    double expense1 = Double.parseDouble(expense);
    double initialAmount = 400.00;
    double assets = initialAmount - newAsset1;

    System.out.println("Your Total Assets Are: " + assets);
    System.out.println("Your Expenses This Month Are: " + expense1);
    System.out.println("Your Expenses Were Due To: " + description);
    }
    catch (IOException err) {
    System.out.println("Error reading line");
    }
    catch(NumberFormatException err) {
    System.out.println("Error Converting Number");
    }
    }
    }

  4. #4
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,189
    Rep Power
    19

    Default Re: netbeans budget code help?

    Look around the FAQs of the site and discover how to post code so that it retains its formatting.

    db
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

Similar Threads

  1. Netbeans GUI source code
    By nksjolinder in forum New To Java
    Replies: 2
    Last Post: 09-21-2011, 10:24 PM
  2. How do I run this code in Netbeans?
    By TaxpayersMoney in forum New To Java
    Replies: 5
    Last Post: 07-28-2011, 07:47 AM
  3. How do I get this code to work in netbeans?
    By TaxpayersMoney in forum NetBeans
    Replies: 1
    Last Post: 07-27-2011, 12:38 AM
  4. NetBeans - error in code?
    By Sparky in forum NetBeans
    Replies: 4
    Last Post: 02-03-2011, 02:51 AM
  5. How to transfer my code to NetBeans IDE
    By ntagrafix in forum New To Java
    Replies: 18
    Last Post: 11-24-2009, 04:33 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •