Help with a java program

Hello. I'm posting in these forums because I really don't know where else to go. I have been trying for the past several days to figure out how to go about writing my program but to no avail. The project requires reading many lines each containing several different elements from a datafile named "DATA". A few examples of some lines from that file:
Department number/Number of units received/Date on which the shipment arrived/Expiration date/Name of Object
0 78 02/03/2001 02/12/2001 apples
0 26 06/03/2001 06/10/2001 lemons
3 62 03/06/2001 03/14/2001 hamburger
What we have to do with this data is read all of it from the file, separate all the different elements, and based on input from the user, sort everything and print it out to the screen. If the user enters 03, the program will show everything that arrived and expired within the month of March, sorted by date.
It is a pretty basic program, but my problem is that I have no idea how to go about reading in this data, putting it into a vector (probably the easiest method) or separating the different elements. I've gone to websites and looked through my textbooks but they didn't help much. If anyone has any resources that could help for writing such a program, or if anyone could offer help in writing the program, I would really appreciate it. I can also show what I've managed to write so far, or more details on how the program should work. Thanks in advance.
Matt

since im not a pro like some of the guys on here :),
and believe me thiers people here, who could write your whole app in a hour.
anyways my advice , would be to do a search on the forums for useing.bufferReader()
i think you would need to read the file in with bufferreader then split up each line useing the stringTokenizer and then use some algorithm to compare
the values and split them up into your vector arrays as needed.
thier is also fileinputStream i think you can use that too.

Similar Messages

  • Need Help with a JAVA programming assignment

    How do I write a JAVA program that could be used as the start of an MS-DOS/Windows simulation of the IEEE 802.3 protocol? I am to only code the parts necessary to build the 802.3 frame. For the initial implementation, the Checksum function need not be a CRC function, and the Destination and Source addresses wil be in input, stored, and output, and in dotted-decimal format.
    I need:
    1. A record to describe the frame, with each field being a (byte-) string of the required size, except that the Data field is of variable size. Although the "Source address" and "Destination address" would be 6 bytes for a real implementation, for this first implementation you can either assume they'll be text strings in the usual "dotted decimal" form (e.g. "14.04.05.18.01.25" as a typical example--from Tanenbaum, p. 429), or 6 hex digits.
    2. Suitable constant declarations for values such as the standard "Preamble" and "Start of Frame" values.
    3. Suitable functions to Get the three variable values "Destination address", "Source address", and "Data" from the standard input device.
    4. A suitable function to display each of the fields of a given frame in a format such as:
    Preamble: ...
    StartofFrame: ...
    Destination: ...
    etc.
    5. A suitable function to generate a "Pad" field if necessary.
    6. A "dummy" Checksum-generating function which just takes the first 32 bits (4 bytes) of the Data (or Data+Pad, if necessary) rather than an actual CRC algorithm.
    I have no experience with Java. Can you help me or start me in the right direction?
    Thanks...........TK

    If you have no experience with Java, then it seems to me your first step should be to start learning the language. But it's difficult to advise how, since we don't know anything about your background. There are many good books available on Java, some are for beginners and some are for advanced programmers, so I'd suggest you go somewhere that has a large selection and start looking for something that doesn't seem completely over your head.

  • Need Help with a Java program

    Hey
    I am doing a bachelor of Multimedia and for some reason I was forced to do Programming 1 which is just Java programing.I have been doing pretty well but we have the final exam coming up on Thursday and they told us to learn how to do this question but I have no idea how to do it, could someone please help me?
    Write a program that reads a file containing a list of students' student numbers and names, and then writes out another file in which the students have been formed into project groups.
    Sample input file:
    96439530 Naranek, Kosh
    08532109 Ivanova, Susan
    87642078 Sheridan, John
    44327889 Varner, Dell
    98100023 Kotto, Vir
    66345689 Sinclair, Jeffrey
    77421009 Garibaldi, Michael
    88775544 Winters, Talia
    54321098 Alexander, Lyta
    12345098 Mollari, Londo
    03465499 Takashima, Laurel
    88765432 Kyle, Benjamin
    08876500 Keffer, Warren
    07687878 Cole, Marcus
    For the project course: no group should have more than 5 members; and it is desireable that all groups have as close to 5 members as possible; and that students be allocated to groups alphabetically by family name, as in this sample output file:
    Group 1:
    Lyta Alexander (54321098)
    Susan Ivanova (08532109)
    Benjamin Kyle (88765432)
    John Sheridan (87642078)
    Dell Varner (44327889)
    Group 2:
    Marcus Cole (07687878)
    Warren Keffer (08876500)
    Londo Mollari (12345098)
    Jeffrey Sinclair (66345689)
    Talia Winters (88775544)
    Group 3:
    Michael Garibaldi (77421009)
    Vir Kotto (98100023)
    Kosh Naranek (96439530)
    Laurel Takashima (03465499)
    Students' names are first sorted (Alexander, Cole, Garibaldi, Ivanova, ...), then allocated to the tutes in rotation (Alexander to 1, Cole to 2, Garibaldi to 3, Ivanova to 1, ...).
    Note also that the student's details are written in a different format from the input. You may make the (usually wrong!) assumption that each student has a simple one-word family name and one other name.

    I'm sorry too annoy you again but I don't know how to implement what you told me. Here is my current code:
    import java.io.*;
    import java.util.*;
    class DetailSortTest {
         public void run() {
              try {
                   BufferedReader in = new
                   BufferedReader(new FileReader ("Data.txt"));
                   String line = in.readLine();
                   String[] names = new String [10];
                   int i = 0;
                   PrintWriter FileOut = new
                   PrintWriter(new FileWriter ("Data 2.txt"));
                   processFilesTest(in, FileOut);
                   in.close();
                   FileOut.close();
              } catch (FileNotFoundException f) {
                   System.out.println("Could Not Open The File");
              } catch (IOException i){
                   System.out.println(i.getMessage());
         public void processFilesTest (BufferedReader in, PrintWriter FileOut)
         throws IOException {
              String data[] = new String[100];
              List dList = new ArrayList();
              String NLine = in.readLine();
              FileOut.println(NLine);
         public static void main(String[] args) {
              DetailSortTest anObject = new
              DetailSortTest();
              anObject.run();
    How would I do it I tried:
    NLine.split(data[2]+""+data[1]+""+data[0]);
    But all that displays is null, null, null
    I know I am probably so stupid but I really appreciate the help

  • Help with some Java Programs

    Hi all ..
    i am a new in Java and i need some help with my School Project ,,,
    Will you help me ??
    regards,
    Toota

    People here will answer questions and comment on your code, but don't ecpect them to debug your source nor do your homework for you.

  • Help with Simple JAVA program

    I'm a complete novice with Java. I want to write a Java program to run on Windows 2000 servers to write a list of certain files in a directory into a *.txt file. I hope to add complexity once I have this basic part working. Here's the code I have so far:
    //this Java application finds poll* files
    public class FindPollApp
    //Create File Object
    File dir = new File("d:/jda/windss/poll");
    //List directory
    if(dir.isDirectory())
    String[] dirContents = dir.list();
    for (int i=0; i < dirContents.length; i++)
    System.out.println(dirContents);
    //Iterate through files
    I get the following errors:
    C:\JAVA>javac FindPollApp.java
    FindPollApp.java:9: illegal start of type
    if(dir.isDirectory())
    ^
    FindPollApp.java:18: <identifier> expected
    ^
    2 errors
    Thanks.

    I'm a complete novice with Java. I want to write a
    Java program to run on Windows 2000 servers to write
    a list of certain files in a directory into a *.txt
    file. I hope to add complexity once I have this
    basic part working. Here's the code I have so far:
    //this Java application finds poll* files
    public class FindPollApp
    //Create File Object
    File dir = new File("d:/jda/windss/poll");
    //List directory
    if(dir.isDirectory())
    String[] dirContents = dir.list();
    for (int i=0; i < dirContents.length; i++)
    System.out.println(dirContents);
    //Iterate through files
    I get the following errors:
    C:\JAVA>javac FindPollApp.java
    FindPollApp.java:9: illegal start of type
    if(dir.isDirectory())
    ^
    FindPollApp.java:18: <identifier> expected
    ^
    2 errors
    Thanks.
    You need to create a method and insert your if statement in there

  • Need help with basic Java programming

    I'm having a little bit of trouble with my code. For the sake of argument, I've removed the code I'm having trouble with, because I know it was inaccurate. I'm trying to create a loop so that this program will keep going through and through until the user enters an invalid variable. I thought the default after the case statements was supposed to make the system exit and output my message. Those two problems, the loop and the default, are what I'm really having problems with. My code is posted below.
    import javax.swing.JOptionPane;
    import java.util.Locale;
    import java.text.NumberFormat;
    public class Retail
    public static void main(String args[])
    String firstNum;
    String secondNum;
    String result;
    int prodNum;      //first number to input
    double quantity; //second number to input
    double total = 0.0;     //total of Prod * Quantity Sold for all items
    // To use American Dollar
    NumberFormat moneyFormat = NumberFormat.getCurrencyInstance( Locale.US );
    // first number entered as string
    firstNum = JOptionPane.showInputDialog( "Enter product number 1-5" );
    // second number entered as string
    secondNum = JOptionPane.showInputDialog( " Enter quantity of items sold" );
    // convert values to type double or int from type string
    prodNum = Integer.parseInt( firstNum );
    quantity = Double.parseDouble( secondNum);
    result="";
    if ( prodNum >=1 && prodNum <=5 ) {
    switch (prodNum)
    case 1: // 1st product
    total = 2.98 * quantity;
    break;
    case 2: // 2nd product
    total = 4.50 * quantity;
    break;
    case 3: // 3rd product
    total = 9.98 * quantity;
    break;
    case 4: //4th product
    total = 4.49 * quantity;
    break;
    case 5:
    total = 6.87 * quantity;
    break;
    default: JOptionPane.showMessageDialog( null, "Wrong product number entered" );
    JOptionPane.showMessageDialog( null, moneyFormat.format(total), "Total Price of Items Purchased", JOptionPane.INFORMATION_MESSAGE );
    System.exit(0);
    ***I know I need to put something in the user input message to state that any value other than 1-5 entered will cause the program to skip to the output, I'll put that in later.***

    When you post code, please use [code] and [/code] tags as described in Formatting Help on the message entry page. It makes it much easier to read and prevents accidental markup from array indices like [i].

  • Need Help with a Java programming exercise.

    I have to Write a program that reads two times in military format (0900, 1730) and prints the number of hours and minutes between two times. Supply your own test program. Here are two sample runs. User inputs are the numbers.
    Please enter the first time: 0900
    Please enter the second time: 1730
    8 hours 30 minutes
    Please enter the first time: 1730
    Please enter the second time: 0900
    15 hours 30 minutes
    Test Program I can write up myself. But the entire constructor I have no idea how to start. This is basic Java Coding. no C++ no importing anything.
    So far this is what I got and I'm sure it's wrong:
    public class TimeInterval
    private double hours;
    private double minutes;
    public TimeInterval(double Time1, double Time2)
    hours =
    minutes =
    }

    tad2382 wrote:
    Jverd,
    I'm guessing that in your early days on this forum you must have spent a lot of time explaining constructors, object creation, etc. Now, after some 40K posts to the forum, you figure newbies should just go and read the documentation. Is that what a lot of veteran posters feel?Perhaps the OP is not aware of the fact the Sun has a good deal of high quality study material published on their website. What's wrong with posting it in a thread? Why should one copy the same thing over and over again? If after reading that tutorial, the OP still has some questions about it, s/he is free to post a follow up question. I am sure that many of the regulars here are more than happy to answer them.
    Also note that the OP's problem description is rather vague. A "I don't know where to start" is IMO best answered by a link to a comprehensive tutorial or a beginners book.
    Being one of the (relatively) novice posters on the forum, I still feel the need to customize posts,Well, by all means: do so.
    trying to see things from the poster's side. Maybe after a few thousand posts, I'll just keep throwing the same documentation at newbies, instead of detailed customized responses, heh.IMO, that's a load of cr@p.

  • Help with inventory Java program

    Hello,
    I've been working on this and couldn't get what's the problem is :(
    Can somebody explain to me what would be the problems?
    import java.util.Scanner;
    public class Product
         public static void main(String[] args)
                   Scanner s = new Scanner(System.in);
                   System.out.print("Enter the item number: ");
                   int item = s.nextInt();
                   System.out.print("Enter the product name: ");
                   String product = s.next();
                   System.out.print("Enter the unit: ");
                   int unit = s.nextInt();
                   System.out.print("Enter the price for each unit: ");
                   double price = s.nextDouble();
                   product p = new product(item, product, unit, price);
                   System.out.println("You entered: ");
                   System.out.print("Item: " + p.getItemNumber() + "\nProduct: " + p.getProductName() + "\nUnits: " + p.getUnits() + "\nPricePerUnit: " + p.getPriceUnit() + "\n");
                   System.out.println("Here is the value of inventory :" + p.getPriceInventory());
    class Inventory1
         private int itemNumber;
         private String productName;
         private int Unit;
         private double priceUnit;
         public Inventory1(int itemNumber, String productName, int Unit, double priceUnit)
              this.itemNumber = itemNumber;
              this.productName = productName;
              this.Unit = Unit;
              this.priceUnit = priceUnit;
         public int getItemNumber()
              return itemNumber;
         public void setItemNumber(int itemNumber)
              this.itemNumber = itemNumber;
         public double getPriceUnit()
              return priceUnit;
         public void setPriceUnit(double priceUnit)
              this.priceUnit = priceUnit;
         public String getProductName()
              return productName;
         public void setProductName(String productName)
              this.productName = productName;
         public int getUnit()
              return Unit;
         public void setUnit(int Unit)
              this.Unit = Unit;
         public double getPriceInventory()
              double number = getUnit() * getPriceUnit();
              return number;
    }Build output:
    --------------------Configuration: <Default>--------------------
    java:10: class Product is public, should be declared in a file named Product.java
    public class Product
           ^
    TestProduct.java:23: cannot find symbol
    symbol  : class product
    location: class Product
                product p = new product(item, product, unit, price);
                ^
    TestProduct.java:23: cannot find symbol
    symbol  : class product
    location: class Product
                product p = new product(item, product, unit, price);
                                ^
    3 errors
    Process completed.General output:
    java.lang.NoClassDefFoundError: Product
    Caused by: java.lang.ClassNotFoundException: Product
        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
    Exception in thread "main"
    Process completed.Help!!
    Thank you in advance

    I adjusted and this time it says:
    Build Output
    --------------------Configuration: <Default>--------------------
    16: cannot find symbol
    symbol  : variable product
    location: class Product
                Product p = new Product(item, product, unit, price);
                                              ^
    16: internal error; cannot instantiate Product.<init> at Product to ()
                Product p = new Product(item, product, unit, price);
                            ^18: cannot find symbol
    symbol  : method getItemNumber()
    location: class Product
                System.out.print("Item: " + p.getItemNumber() + "\nProduct: " + p.getProductName() + "\nUnits: " + p.getUnits() + "\nPricePerUnit: " + p.getPriceUnit() + "\n");
                                             ^
    18: cannot find symbol
    symbol  : method getProductName()
    location: class Product
                System.out.print("Item: " + p.getItemNumber() + "\nProduct: " + p.getProductName() + "\nUnits: " + p.getUnits() + "\nPricePerUnit: " + p.getPriceUnit() + "\n");
                                                                                 ^
    18: cannot find symbol
    symbol  : method getUnits()
    location: class Product
                System.out.print("Item: " + p.getItemNumber() + "\nProduct: " + p.getProductName() + "\nUnits: " + p.getUnits() + "\nPricePerUnit: " + p.getPriceUnit() + "\n");
                                                                                                                    ^
    18: cannot find symbol
    symbol  : method getPriceUnit()
    location: class Product
                System.out.print("Item: " + p.getItemNumber() + "\nProduct: " + p.getProductName() + "\nUnits: " + p.getUnits() + "\nPricePerUnit: " + p.getPriceUnit() + "\n");
                                                                                                                                                        ^
    19: cannot find symbol
    symbol  : method getPriceInventory()
    location: class Product
                System.out.println("Here is the value of inventory :" + p.getPriceInventory());
                                                                         ^
    7 errors
    Process completed.General Output
    --------------------Configuration: <Default>--------------------
    java.lang.NoClassDefFoundError: Product
    Caused by: java.lang.ClassNotFoundException: Product
        at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
    Exception in thread "main"
    Process completed.(>_<)
    I forgot to mention...
    That I need to create a product class that holds the item number, the name of the product, the number of units in stock and the price of each unit (I think I got this part)
    I need to create a Java application that displays the product number, the name of the product, the number of units in stock, the price of each unit, and the value of the inventory (the number of units in stock multiplied by the price of each unit).
    Edited by: yodartas on Sep 27, 2008 7:54 PM

  • Need help with my addressbook program

    hi,
    i need help with my program here. this one should works as:
    - saves user input into a txt file
    - displays name of the saved person on the jlist whenever i run the program
    - displays info about the person when clicked via textboxes given by reading the txt file where the user inputs are
    - should scroll when the list exceeds the listbox
    import java.awt.event.*;
    import java.awt.*;
    import javax.swing.*;
    import javax.swing.JList;
    import java.awt.event.ActionListener;
    import java.io.*;
    import javax.swing.event.*;
    import java.io.FilterInputStream;
    public class AddressList extends JPanel implements ActionListener
         JTextField txt1 = new JTextField();
         JTextField txt2 = new JTextField();
         JTextField txt3 = new JTextField();
         DefaultListModel mdl = new DefaultListModel();
         JList list = new JList();
         JScrollPane listScroller = new JScrollPane(list);
         ListSelectionModel listSelectionModel;
         File fob = new File("Address3.txt");
         String name;
         char[] chars;     
         public void ListDisplay()
              try
                   RandomAccessFile rand = new RandomAccessFile(fob,"rw");
                   BufferedReader br = new BufferedReader(new FileReader("Address3.txt"));
                   if(fob.exists())
                         while((name = rand.readLine()) != null)
                              chars = name.toCharArray();
                              if(chars[0] == '*')
                                   mdl.addElement(name);
                                   list.setModel(mdl);
                              if(chars[0] == '#')
                                   continue;
                    else
                        System.out.println("No such file..");
              catch(IOException a)
                         System.out.println(a.getMessage());
         public AddressList()
              this.setLayout(null);
              listSelectionModel = list.getSelectionModel();
            listSelectionModel.addListSelectionListener(new ListInfo());
              list.setBounds(10,40,330,270);
              listScroller.setBounds(320,40,20,100);
              add(list);
              add(listScroller);
              JLabel lbl4 = new JLabel("Name: ");
              lbl4.setBounds(400,10,80,30);
              add(lbl4);
              JLabel lbl5 = new JLabel("Cellphone #: ");
              lbl5.setBounds(400,50,80,30);
              add(lbl5);
              JLabel lbl6 = new JLabel("Address: ");
              lbl6.setBounds(400,90,80,30);
              add(lbl6);
              JLabel lbl7 = new JLabel("List ");
              lbl7.setBounds(10,10,100,30);
              add(lbl7);
              txt1.setBounds(480,10,200,30);
              add(txt1);
              txt2.setBounds(480,50,200,30);
              add(txt2);
              txt3.setBounds(480,90,200,30);
              add(txt3);
              JButton btn1 = new JButton("Add");
              btn1.setBounds(480,130,100,30);
              btn1.addActionListener(this);
              btn1.setActionCommand("Add");
              add(btn1);
              JButton btn2 = new JButton("Save");
              btn2.setBounds(480,170,100,30);
              btn2.addActionListener(this);
              btn2.setActionCommand("Save");
              add(btn2);
              JButton btn3 = new JButton("Cancel");
              btn3.setBounds(480,210,100,30);
              btn3.addActionListener(this);
              btn3.setActionCommand("Cancel");
              add(btn3);
              JButton btn4 = new JButton("Close");
              btn4.setBounds(480,250,100,30);
              btn4.addActionListener(this);
              btn4.setActionCommand("Close");
              add(btn4);
         public static void main(String[]args)
              JFrame frm = new JFrame("Address List");
              AddressList panel = new AddressList();
              frm.getContentPane().add(panel,"Center");
              frm.setSize(700,350);
              frm.setVisible(true);
              panel.ListDisplay();
         public void actionPerformed(ActionEvent e)
              String cmd;
              cmd = e.getActionCommand();
              if(cmd.equals("Add"))
                   txt1.setText("");
                   txt2.setText("");
                   txt3.setText("");
              else if(cmd.equals("Save"))
                   mdl.addElement(txt1.getText());
                   list.setModel(mdl);
                   try
                   RandomAccessFile rand = new RandomAccessFile(fob,"rw");
                   BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
                   LineNumberReader line = new LineNumberReader(br);
                    if(fob.exists())
                              rand.seek(fob.length());
                              rand.writeBytes("* " + txt1.getText());
                              rand.writeBytes("\r\n" + "# " + txt2.getText());
                              rand.writeBytes("\r\n" + "# " + txt3.getText() + "\r\n");
                    else
                         System.out.println("No such file..");
                        txt1.setText("");
                        txt2.setText("");
                        txt3.setText("");
                    catch(IOException a)
                         System.out.println(a.getMessage());
              else if(cmd.equals("Cancel"))
                   txt1.setText("");
                   txt2.setText("");
                   txt3.setText("");
              else if(cmd.equals("Close"))
                   System.exit(0);
    class ListInfo implements ListSelectionListener
         public void valueChanged(ListSelectionEvent e)
              ListSelectionModel lsm = (ListSelectionModel)e.getSource();
              int minIndex = lsm.getMinSelectionIndex();
            int maxIndex = lsm.getMaxSelectionIndex();
              try //*this one should display the info of the person whenever i click the person's name at the list box via textbox.. but i cant seem to get it right since it always display the info of the first person inputed.. i tried to get the program to display them whenever it reads lines with * on them....
                   File fob = new File("Address3.txt");
                   RandomAccessFile rand = new RandomAccessFile(fob,"rw");
                   BufferedReader br = new BufferedReader(new FileReader("Address3.txt"));
                   LineNumberReader line = new LineNumberReader(br);
                   if(fob.exists())
                              for(int i = minIndex; i<=maxIndex; i++)
                                   if(lsm.isSelectedIndex(i))
                                        while((name = rand.readLine()) != null)
                                             chars = name.toCharArray();
                                             if(chars[0] == '#')
                                                  continue;
                                             if(chars[0] == '*')
                                                  txt1.setText(rand.readLine());
                                                 txt2.setText(rand.readLine());
                                                 txt3.setText(rand.readLine());
                    else
                              System.out.println("No such file..");
              catch(IOException a)
                         System.out.println(a.getMessage());
    }the only problem now is about how it should display the right info about the person whenever i click its name on the list.. something about file reading or something, i just cant figure it out.
    and also about how to make it scroll once it exceeds the list.. i cant make it work, maybe something about wrong declaration..
    thanks in advance..
    Edited by: syder on Mar 14, 2008 2:26 AM

    Like said before, do one thing at a time. At startup, something like:
    //put all the content in a list
    ArrayList<String> lines = new ArrayList<String>();
    while(String line=rand.readLine()!=null) {
        lines.add(line);
    }If you follow the good advice to create a class to encapsulate the entries, you could populate a list of such entries like this:
    static final int ENTRY_SIZE = 3;//you have 3 fields now, better to have a constant if that changes
    ArrayList<Entry> entries = new ArrayList<Entry>();
    for(int i=0; i<lines.size(); i+=ENTRY_SIZE) {
        Entry entry = new Entry(lines.get(i), lines.get(i+1), lines.get(i+2);
        entries.add(newEntry);
    }You could also do both of the above in one run, but I think you will understand better what's happening if you do one thing at a time.
    If you don't want to put the entries in an encapsulating class, you can still access this without looping:
    int listStartIdx = <desired_entry_index>*ENTRY_SIZE;
    String att1 = lines.get(listStartIdx).substring(1);
    String att2 = lines.get(listStartIdx+1).substring(1);
    String att3 = lines.get(listStartIdx+2).substring(1);

  • Need help with a rudimentary program

    I'm sort of new at this so i need help with a few things... I'm making a program to compile wages and i need answers with three things: a.) what are the error messages im getting meaning? b.) How can i calculate the state tax as 2% of my gross pay with the first $200 excluded and c.) how can i calculate the local tax as a flat $10 with $2 deducted for each dependant. any help is appreciated
    Here is what i have so far:
    public class WagesAsign1
              public static void main(String[] args)
                   int depend=4;
                   double hrsWork=40;
                   double payRate=15;
                   double grossPay;
                   grossPay=payRate*hrsWork;
                   double statePaid;
                   double stateTax=2.0;
                   statePaid=grossPay*(stateTax/100);
                   double localPaid;
                   double localTax=10.0;
                   localPaid=grossPay*(localTax/100);
                   double fedPaid;
                   double fedTax=10.0;
                   double taxIncome;
                   fedPaid=taxIncome*(fedTax/100);
                   taxIncome=grossPay-(statePaid+localPaid);
                   double takeHome;
                   System.out.println("Assignment 1 Matt Foraker\n");
                   System.out.println("Hours worked="+hrsWork+" Pay rate $"+payRate+" per/hour dependants: "+depend);
                   System.out.println("Gross Pay $"+grossPay+"\nState tax paid $"+statePaid+"\nLocal tax paid $"+localPaid+"\nFederal tax paid $"+fedPaid);
                   System.out.println("You take home a total of $"+takeHome);
    and these are the error messages so far:
    WagesAsign1.java:23: variable taxIncome might not have been initialized
                   fedPaid=taxIncome*(fedTax/100);
    ^
    WagesAsign1.java:29: variable takeHome might not have been initialized
                   System.out.println("You take home a total of $"+takeHome);
    ^

    edit: figured it out... please delete post
    Message was edited by:
    afroryan58

  • Need Help With D&D Program

    Hi, I'm not sure if I'm allowed to post questions on this forum but I can't find anywhere to talk to helpful people about programming.
    I'm making a dnd interface for JComponents. So far I've made a simple program that has a Component that can be lifted from a container and braught to the glass pane then later moved to anywhere on the screen and dropped into the container below it. Here's where my problems come:
    1) Rite now my 'Movable Component' is a JPanel which is just colored in. I want to either take a Graphic2d from a JComponent/Component and draw it on the JPanel or change the JPanel to the component I want to paint and disable the component.
    The problem with getting the Graphics2d is that if the component isn't on the screen it doesn't make a graphic object. I tried messing with the ui delicate and overriding parental methods for paintComponent, repaint, and that repaintChildren(forget name) but I haven't had luck getting a good graphics object. I was thinking of, at the beginning of running the program, putting 1 of each component onto the screen for a second then removing it but I'd rather not. I'd also like to change the graphics dynamicly if someone stretches the component there dropping and what not.
    The problem with disabling is that it changes some of the visual features of Components. I want to be able to update the Component myself to change how it looks and I don't want disabling to gray out components.
    I mainly just dont want the components to do any of there normal fuctions. This is for a page builder, by the way.
    Another problem I'm having is that mouseMotionListener is allowing me to select 2 components that are on top of one another when there edges are near each other. I don't know if theres a fix to this other than changing the Java Class.
    My next problem is a drop layout manager, but I'm doing pretty good with that rite now. It'll problem just move components out of the way of the falling component.
    One last thing I need help with is that I don't want the object that's being carried to go across the menu bar and certain areas. When I'm having the object being carried I have it braught up to the glass pane which allows it to move anywhere. Does anyone have any idea how I could prevent the component from being over the menu bars and other objects? I might have to make 1 panel is the movable area that can then be broken down into the 'component bank', 'building page' and whatever else I'm gonna need.
    This is all just test code to get together for when I make the real program but I need to make sure it'll be possible without a lot of hacking of code.
    Sorry for the length. Thanks for any help you can give.

    The trick to making viewable components that have no behaviour, is to render them onto an image of some sort (eg a BufferedImage). You can then display the Image on a JLabel that can be dragged around the desktop.
    Here is a piece of code that does the component rendering for you. This particular example uses a fixed component size, but you can modify that as you choose of course...public class JComponentImage
         private static GraphicsConfiguration gConfig;
         private static Dimension compSize = new Dimension(80, 22);
         private static Image image = null;
         public static Image getImage(Class objectClass)
              if (gConfig == null)
                   GraphicsEnvironment gEnv = GraphicsEnvironment.getLocalGraphicsEnvironment();
                   GraphicsDevice gDevice = gEnv.getDefaultScreenDevice();
                   gConfig = gDevice.getDefaultConfiguration();
              image = gConfig.createCompatibleImage(compSize.width, compSize.height);
              JComponent jc = (JComponent) ObjectFactory.instantiate(objectClass);
              jc.setSize(compSize);
              Graphics g = image.getGraphics();
              g.setColor(Color.LIGHT_GRAY);
              g.fillRect(0, 0, compSize.width, compSize.height);
              g.setColor(Color.BLACK);
              jc.paint(g);
              return image;
    }And here is the class that makes the dragable JLabel using the class above...public class Dragable extends JLabel
         private static DragSource dragSource = DragSource.getDefaultDragSource();
         private static DragGestureListener dgl = new DragMoveGestureListener();
         private static TransferHandler th = new ObjectTransferHandler();
         private Class compClass;
         private Image image;
         Dragable(Class compClass)
              this.compClass = compClass;
              image = JComponentImage.getImage(compClass);
              setIcon(new ImageIcon(image));
              setTransferHandler(th);
              dragSource.createDefaultDragGestureRecognizer(this,
                                                          DnDConstants.ACTION_COPY,
                                                          dgl);
         public Class getCompClass()
              return compClass;
    }Oh and here is ObjectFactory which simply instantiates Objects of a given class and sets their text to their classname (very crudely)...public class ObjectFactory
         public static Object instantiate(Class objectClass)
              Object o = null;
              try
                   o = objectClass.newInstance();
              catch (Exception e)
                   System.out.println("ObjectFactory#instantiate: " + e);
              String name = objectClass.getName();
              int lastDot = name.lastIndexOf('.');
              name = name.substring(lastDot + 1);
              if (o instanceof JLabel)
                   ((JLabel)o).setText(name);
              if (o instanceof JButton)
                   ((JButton)o).setText(name);
              if (o instanceof JTextComponent)
                   ((JTextComponent)o).setText(name);
              return o;
    }Two more classes required by this codepublic class ObjectTransferHandler extends TransferHandler {
         private static DataFlavor df;
          * Constructor for ObjectTransferHandler.
         public ObjectTransferHandler() {
              super();
              try {
                   df = new DataFlavor(DataFlavor.javaJVMLocalObjectMimeType);
              } catch (ClassNotFoundException e) {
                   Debug.trace(e.toString());
         public Transferable createTransferable(JComponent jC) {
              Transferable t = null;
              try {
                   t = new ObjectTransferable(((Dragable) jC).getCompClass());
              } catch (Exception e) {
                   Debug.trace(e.toString());
              return t;
         public int getSourceActions(JComponent c) {
              return DnDConstants.ACTION_MOVE;
         public boolean canImport(JComponent comp, DataFlavor[] flavors) {
              if (!(comp instanceof Dragable) && flavors[0].equals(df))
                   return true;
              return false;
         public boolean importData(JComponent comp, Transferable t) {
              JComponent c = null;
              try {
                   c = (JComponent) t.getTransferData(df);
              } catch (Exception e) {
                   Debug.trace(e.toString());
              comp.add(c);
              comp.validate();
              return true;
    public class ObjectTransferable implements Transferable {
         private static DataFlavor df = null;
         private Class objectClass;
         ObjectTransferable(Class objectClass) {
              try {
                   df = new DataFlavor(DataFlavor.javaJVMLocalObjectMimeType);
              } catch (ClassNotFoundException e) {
                   System.out.println("ObjectTransferable: " + e);
              this.objectClass = objectClass;
          * @see java.awt.datatransfer.Transferable#getTransferDataFlavors()
         public DataFlavor[] getTransferDataFlavors() {
              return new DataFlavor[] { df };
          * @see java.awt.datatransfer.Transferable#isDataFlavorSupported(DataFlavor)
         public boolean isDataFlavorSupported(DataFlavor testDF) {
              return testDF.equals(df);
          * @see java.awt.datatransfer.Transferable#getTransferData(DataFlavor)
         public Object getTransferData(DataFlavor arg0)
              throws UnsupportedFlavorException, IOException {
              return ObjectFactory.instantiate(objectClass);
    }And of course the test class:public class DragAndDropTest extends JFrame
         JPanel leftPanel = new JPanel();
         JPanel rightPanel = new JPanel();
         Container contentPane = getContentPane();
         Dragable dragableJLabel;
         Dragable dragableJButton;
         Dragable dragableJTextField;
         Dragable dragableJTextArea;
          * Constructor DragAndDropTest.
          * @param title
         public DragAndDropTest(String title)
              super(title);
              dragableJLabel = new Dragable(JLabel.class);
              dragableJButton = new Dragable(JButton.class);
              dragableJTextField = new Dragable(JTextField.class);
              dragableJTextArea = new Dragable(JTextArea.class);
              leftPanel.setBorder(new EtchedBorder());
              BoxLayout boxLay = new BoxLayout(leftPanel, BoxLayout.Y_AXIS);
              leftPanel.setLayout(boxLay);
              leftPanel.add(dragableJLabel);
              leftPanel.add(dragableJButton);
              leftPanel.add(dragableJTextField);
              leftPanel.add(dragableJTextArea);
              rightPanel.setPreferredSize(new Dimension(500,500));
              rightPanel.setBorder(new EtchedBorder());
              rightPanel.setTransferHandler(new ObjectTransferHandler());
              contentPane.setLayout(new BorderLayout());
              contentPane.add(leftPanel, "West");
              contentPane.add(rightPanel, "Center");
         public static void main(String[] args)
              JFrame frame = new DragAndDropTest("Drag and Drop Test");
              frame.pack();
              frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
              frame.setVisible(true);
    }I wrote this code some time ago, so it won't be perfect but hopefully will give you some good ideas.
    Regards,
    Tim

  • Problem with running java program

    Hey again!
    I missed out some information in last posting.. here is the full description
    I have just installed 1.5.0_06 and have set paths and what otherwise is necessary to run the java programs. I was testing the install and run a standard HelloWorld.java program
    I got the following error:
    Exception in thread main java.lang.NoClassDefFoundError: HelloWorld
    what is wrong...
    Here is the entire HelloWorld.java
    public class HelloWorld
    public HelloWorld()
    System.out.println("Hello World");
    public static void main(String[] args)
    HelloWorld hw = new HelloWorld();
    I have checked that the path is correct too..
    Hopefully someone can help me!
    Anders

    Your Path is set, probably the problem is classpath.
    Change the cmd/command prompt to the directory that contains your HelloWorld.class file, verifying that it exists. If it does, issue this command from that directory:
    java -cp . HelloWorld
    Important: include the period and surrounding spaces
    If that works, you can learn about setting and using the classpath here:
    http://java.sun.com/j2se/1.5.0/docs/tooldocs/index.html#general
    By the way, just add a reply to your original post with the additional information, rather than creating another post. That eliminates duplication of replies.

  • Need help with a simple program (should be simple anyway)

    I'm (starting to begin) writing a nice simple program that should be easy however I'm stuck on how to make the "New" button in the file menu clear all the fields. Any help? I'll attach the code below.
    ====================================================
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class Message extends JFrame implements ActionListener {
         public void actionPerformed(ActionEvent evt) {
         text1.setText(" ");
         text2.setText("RE: ");
         text3.setText(" ");
         public Message() {
         super("Write a Message - by Kieran Hannigan");
         setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
         setSize(370,270);
         FlowLayout flo = new FlowLayout(FlowLayout.RIGHT);
         setLayout(flo);
         //Make the bar
         JMenuBar bar = new JMenuBar();
         //Make "File" on Menu
         JMenu File = new JMenu("File");
         JMenuItem f1 = new JMenuItem("New");f1.addActionListener(this);
         JMenuItem f2 = new JMenuItem("Open");
         JMenuItem f3 = new JMenuItem("Save");
         JMenuItem f4 = new JMenuItem("Save As");
         JMenuItem f5 = new JMenuItem("Exit");
         File.add(f1);
         File.add(f2);
         File.add(f3);
         File.add(f4);
         File.add(f5);
         bar.add(File);
         //Make "Edit" on menu
         JMenu Edit = new JMenu("Edit");
         JMenuItem e1 = new JMenuItem("Cut");
         JMenuItem e2 = new JMenuItem("Paste");
         JMenuItem e3 = new JMenuItem("Copy");
         JMenuItem e4 = new JMenuItem("Repeat");
         JMenuItem e5 = new JMenuItem("Undo");
         Edit.add(e5);
         Edit.add(e4);
         Edit.add(e1);
         Edit.add(e3);
         Edit.add(e2);
         bar.add(Edit);
         //Make "View" on menu
         JMenu View = new JMenu("View");
         JMenuItem v1 = new JMenuItem("Bold");
         JMenuItem v2 = new JMenuItem("Italic");
         JMenuItem v3 = new JMenuItem("Normal");
         JMenuItem v4 = new JMenuItem("Bold-Italic");
         View.add(v1);
         View.add(v2);
         View.add(v3);
         View.addSeparator();
         View.add(v4);
         bar.add(View);
         //Make "Help" on menu
         JMenu Help = new JMenu("Help");
         JMenuItem h1 = new JMenuItem("Help Online");
         JMenuItem h2 = new JMenuItem("E-mail Programmer");
         Help.add(h1);
         Help.add(h2);
         bar.add(Help);
         setJMenuBar(bar);
         //Make Contents of window.
         //Make "Subject" text field
         JPanel row2 = new JPanel();
         JLabel sublabel = new JLabel("Subject:");
         row2.add(sublabel);
         JTextField text2 = new JTextField("RE:",24);
         row2.add(text2);
         //Make "To" text field
         JPanel row1 = new JPanel();
         JLabel tolabel = new JLabel("To:");
         row1.add(tolabel);
         JTextField text1 = new JTextField(24);
         row1.add(text1);
         //Make "Message" text area
         JPanel row3 = new JPanel();
         JLabel Meslabel = new JLabel("Message:");
         row3.add(Meslabel);
         JTextArea text3 = new JTextArea(6,22);
         messagearea.setLineWrap(true);
         messagearea.setWrapStyleWord(true);
         JScrollPane scroll = new JScrollPane(text3,
                                  JScrollPane.VERTICAL_SCROLLBAR_ALWAYS,
                                  JScrollPane.HORIZONTAL_SCROLLBAR_NEVER);
         //SpaceLine
         JPanel spaceline = new JPanel();
         JLabel spacer = new JLabel(" ");
         spaceline.add(spacer);
         row3.add(scroll);
         add(row1);
         add(row2);
         add(spaceline);
         add(spaceline);
         add(row3);
         setVisible(true);
         public static void main(String[] arguments) {
         Message Message = new Message();
    }

    persiandude wrote:
    Topic: Need help with if, else, and which statements and loops.
    How would I display 60 < temp. <= 85 in java
    System.out.println("60 < temp. <= 85 in java");
    another question is how do I ask a question like want to try again (y/n) after a output and asking that everytime I type in yes after a output and terminate when saying No.Sun's [basic Java tutorial|http://java.sun.com/docs/books/tutorial/]
    Sun's [New To Java Center|http://java.sun.com/learning/new2java/index.html].Includes an overview of what Java is, instructions for setting up Java, an intro to programming (that includes links to the above tutorial or to parts of it), quizzes, a list of resources, and info on certification and courses.
    [http://javaalmanac.com|http://javaalmanac.com]. A couple dozen code examples that supplement [The Java Developers Almanac|http://www.amazon.com/exec/obidos/tg/detail/-/0201752808?v=glance].
    jGuru. A general Java resource site. Includes FAQs, forums, courses, more.
    JavaRanch. To quote the tagline on their homepage: "a friendly place for Java greenhorns." FAQs, forums (moderated, I believe), sample code, all kinds of goodies for newbies. From what I've heard, they live up to the "friendly" claim.
    Bruce Eckel's [Thinking in Java|http://mindview.net/Books/DownloadSites] (Available online.)
    Joshua Bloch's [Effective Java|http://www.amazon.com/Effective-Java-2nd-Joshua-Bloch/dp/0321356683/ref=pd_bbs_1?ie=UTF8&s=books&qid=1214349768&sr=8-1]
    Bert Bates and Kathy Sierra's [Head First Java|http://www.amazon.com/exec/obidos/tg/detail/-/0596004656?v=glance].
    James Gosling's [The Java Programming Language|http://www.bookpool.com/sm/0321349806].

  • Help with a simple program.

    I need some help writing a simple program. Can anybody help??
    thanks to all.
    2. HTML Java Source Code Reserved Word Highlighter
    Write a program that inputs a Java source code file and outputs a copy of that file with Java keywords surrounded with HTML tags for bold type. For example this input:
    public class JavaSource
    public static void main ( String[] args )
    if ( args.length == 3 )
    new BigObject();
    else
    System.out.println("Too few arguments.");
    will be transformed into:
    <B>public</B> <B>class</B> JavaSource
    <B>public</B> <B>static</B> <B>void</B> main ( String[] args )
    <B>if</B> ( args.length == 3 )
    <B>new</B> BigObject();
    <B>else</B>
    System.out.println("Too few arguments.");
    In a browser the code will look like this:
    public class JavaSource
    public static void main ( String[] args )
    if ( args.length == 3 )
    new BigObject();
    else
    System.out.println("Too few arguments.");

    Here is something that may get you started...
    import java.io.*; 
    import java.util.*; 
    public class HtmlJava{
         public static void main(String arg[]){
              if(arg.length!=1){
                   System.out.println("Usage java HtmlJava sourceFile");       
              else
                   new HtmlJava(arg[0]);
         HtmlJava(String source){
              try{
                   BufferedReader sourceReader=new BufferedReader(new InputStreamReader(new FileInputStream(source)));
                   BufferedWriter writer=new BufferedWriter(new OutputStreamWriter(new FileOutputStream(source+"Html.txt")));  
                   Vector keywords=new Vector();
                   addKeywords(keywords);
                   String line;
                   StringTokenizer tokenizer=null;
                   String word;
                   while((line=sourceReader.readLine () )!=null){
                        tokenizer=new StringTokenizer(line);
                        while(tokenizer.hasMoreTokens()){
                             word=tokenizer.nextToken();
                             if(keywords.contains(word)){
                                  writer.write(""+word+" ");
                             else{
                                  writer.write(word+" ");
                        writer.write("\r\n");
                   writer.close();
                   sourceReader.close(); 
                   System.out.println("Output File written to "+source+"Html.txt"); 
              catch(Exception ex){
                   ex.printStackTrace();      
         private void addKeywords(Vector keywords){
              keywords.addElement ( "abstract");
              keywords.addElement( "boolean");
              keywords.addElement( "break");
              keywords.addElement( "byte");
              keywords.addElement( "byvalue");
              keywords.addElement( "case");
              keywords.addElement( "cast");
              keywords.addElement( "catch");
              keywords.addElement( "char");
              keywords.addElement( "class");
              keywords.addElement( "const");
              keywords.addElement( "continue");
              keywords.addElement( "default");
              keywords.addElement( "do");
              keywords.addElement( "double");
              keywords.addElement( "else");
              keywords.addElement( "extends");
              keywords.addElement( "false");
              keywords.addElement( "final");
              keywords.addElement( "finally");
              keywords.addElement( "float");
              keywords.addElement( "for");
              keywords.addElement( "future");
              keywords.addElement( "generic");
              keywords.addElement( "goto");
              keywords.addElement( "if");
              keywords.addElement( "implements");
              keywords.addElement( "import");
              keywords.addElement( "inner");
              keywords.addElement( "instanceof");
              keywords.addElement( "int");
              keywords.addElement( "interface");
              keywords.addElement( "long");
              keywords.addElement( "native");
              keywords.addElement( "new");
              keywords.addElement( "null");
              keywords.addElement( "operator");
              keywords.addElement( "outer");
              keywords.addElement( "package");
              keywords.addElement( "private");
              keywords.addElement( "protected");
              keywords.addElement( "public");
              keywords.addElement( "rest");
              keywords.addElement( "return");
              keywords.addElement( "short");
              keywords.addElement( "static");
              keywords.addElement( "super");
              keywords.addElement( "switch");
              keywords.addElement( "synchronized");
              keywords.addElement( "this");
              keywords.addElement( "throw");
              keywords.addElement( "throws");
              keywords.addElement( "transient");
              keywords.addElement( "true");
              keywords.addElement( "try");
              keywords.addElement( "var");
              keywords.addElement( "void");
              keywords.addElement( "volatile");
              keywords.addElement( "while");
    }Hope it helped

  • Help with an array program

    I can't see how to calculate the lowest hours, highest hours, and average hours worked.
    These three values should be outputted each on a seperate line.
    I just can't figure this out.
    Any help please.
    This program will show the employees
    hours. It will have one
    class.It will use an array to keep
    track of the number of hours the employee
    has worked with the output to the monitor
    of the employees highest, lowest, and the
    average of all hours entered. */
    import java.util.*;
    import java.text.DecimalFormat;
    /*** Import Decimal Formating hours to format hours average. ***/
    public class cs219Arrays
         public static void main(String[] args)
              Scanner scannerObject = new Scanner(System.in);
              int[] employees ={20, 35, 40};
              int employeesHighest = 40;
              int employeesLowest = 20;
              double employeesAverage = 35;
              int[] firstEmployee = new int[1];
              int[] secondEmployee = new int[2];
              int[] thirdEmployee = new int[3];
              System.out.println("This program will accept hours worked for 3 employees.");
              System.out.println("Enter hours worked for employee #: ");
              System.out.println(".\n");
              employeesAverage = scannerObject.nextInt();
              for(int count =20; count <= 40; count++)
                             DecimalFormat df = new DecimalFormat("0.00");
                             System.out.println("pay: " employeesAverage " lowest " employeesHighest " Highest hours " employeesLowest " Lowest hours "+df.format(employeesAverage));
                             System.out.print("\n");
                             employeesAverage++;
    }/* end of body of first for loop */
              for(int count =20; count <= 40; count++)
                                       employeesAverage = employeesAverage + employeesHighest + employeesLowest;
                                       DecimalFormat df = new DecimalFormat("0.00");
                                       System.out.println("pay: $" employeesAverage " lowest " employeesHighest " Highest hours $" +df.format(employeesAverage));
                                       System.out.print("\n");
                                       employeesAverage++;
    }/* end of body of second for loop */
              for(int count =20; count <= 40; count++)
                                       employeesAverage = employeesAverage + employeesHighest + employeesLowest;
                                       DecimalFormat df = new DecimalFormat("0.00");
                                       System.out.println("pay: $" employeesAverage " lowest " employeesHighest " Highest hours $" +df.format(employeesAverage));
                                       System.out.print("\n");
                                       employeesAverage++;
    }/* end of body of third for loop */
              System.out.println("\n");
              DecimalFormat twoDigits = new DecimalFormat("0.00");
              /*** Create new DecimalFormat object named twoDigits ***/
              /*Displays number of hours, employees hours and average hours.*/
              System.out.println("You entered " + employeesAverage + " number of hours.");
              System.out.println("Your number of hours are " + twoDigits.format(employeesAverage));
              System.out.println("\n\n");
    }     /*End of method for data.*/
    {     /*Main method.*/
    }     /*End of main method.*/
    }     /*End of class cs219Arrays.*/

    Want help?
    Use the code formatting tags for starters. http://forum.java.sun.com/help.jspa?sec=formatting

Maybe you are looking for

  • How can I back-up my Itunes library?

    I need to have my MAC (Snow Leopard) hard drive replaced.  How can I back up my iTunes Library?

  • Black screen flashing constantly recent upgrade to Yosemite

    I upgraded to Yosemite yesterday on my brand new macbook pro with retina display and this morning i had some issues with my fonts so as i was looking in the library folder to try and find the font problem all of a sudden my screen went black and then

  • Delete the summarisation  run in plant level

    we runing the summarisation report  from the t.code KKRS. it was fatch the wrong values now i want delete that one please let know the procedure . WIP Process Delete Settlement process delete Order hierarchy Process Delete with t.code  any dacuments 

  • CS6 Encore requiring a second encode of H264 BluRay from media encoder

    Have noticed that when I encode an H264 file in Blu-Ray for encore, that when I try to build the DVD I get a message that the file is not proessed.  If I go back to media encoder and reprocess the existing H264 file, Encore will then accept it.  I th

  • Mac Help quits unexpectedly

    Hi all... I have a PowerBook G4 running Panther 10.3.9, which is almost 4 yrs old. Everything was working just fine, few weeks back when I noticed that the Mac Help (Help botton on the Finder screen) quits unexpectedly. Please help me in fixing this