I need Help with codes. It isn't working

I had once writing a code for finding the factorial of a number in elementary programming with C. I tried to incorporate it into my work. However, it is not working.
Below are the major hitches:
1. I have a problem with entering two numbers by simply pressing the buttons. Once i try to input another number the second number displaces the first on the textfield. Which suffices to say that entering a two or three digit number via the buttons is not working.
2. What I intend to archieve is such once I have enter the numbers using the buttons i could get the factorial of whatever number i entered by simply pressing the n! button. Once i attempt pressing the n! button it displays error in the command prompt (a long list of error comments).
How should I Proceed.
Below is my full code:
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class PanFrame extends JFrame implements ActionListener
     JTextField jTfd =new JTextField(20);
     JButton jbtn7 = new JButton ("7");
     JButton jbtn8 = new JButton ("8");
     JButton jbtn9 = new JButton ("9");
     JButton jbtn4 = new JButton ("4");
     JButton jbtn5 = new JButton ("5");
     JButton jbtn6 = new JButton ("6");
     JButton jbtn1= new JButton ("1");
     JButton jbtn2 = new JButton ("2");
     JButton jbtn3 = new JButton ("3");
     JButton jbtn0 = new JButton ("0");
     JButton jbtnFT = new JButton ("n!");
     public PanFrame (String title)
               super (title);
               Panel pan1 = new Panel();
               getContentPane().setLayout(new FlowLayout ());
               pan1.add(jTfd);
               Panel pan2 = new Panel();
               getContentPane().setLayout (new GridLayout (4,5,2,2));
               pan2.add (jbtn7);
               pan2.add (jbtn8);
               pan2.add (jbtn9);
               pan2.add (jbtn4);
               pan2.add (jbtn5);
               pan2.add (jbtn6);
               pan2.add (jbtn1);
               pan2.add (jbtn2);
               pan2.add (jbtn3);
               pan2.add (jbtn0);
               pan2.add (jbtnFT);
               getContentPane().add(pan1);
               getContentPane().add(pan2);
               //adding the Listener     
               jTfd.addActionListener(this);
                       jbtn7.addActionListener(this);
               jbtn8.addActionListener(this);
               jbtn9.addActionListener(this);
               jbtn4.addActionListener(this);
               jbtn5.addActionListener(this);
               jbtn6.addActionListener(this);
               jbtn1.addActionListener(this);
               jbtn2.addActionListener(this);
               jbtn3.addActionListener(this);
               jbtn0.addActionListener(this);
               jbtnFT.addActionListener(this);
               validate();
               this.addWindowListener (new WindowAdapter()
                    public void windowClosing (WindowEvent we)
                              setVisible (false);
                              System.exit (0);
           public void actionPerformed(ActionEvent ae)
                    jTfd.setText(ae.getActionCommand());
               if(ae.getActionCommand()=="n!")
                              int num= Integer.parseInt(jTfd.getText());
                         int i;
                         long fact=1;
                         for(i=1; i<=num; i++)
                                   fact *=i;
                         jTfd.setText(String.valueOf(fact));
     public static void main (String arg [ ])
               PanFrame ObjFr = new PanFrame ("Two Panel in One Frame");
               ObjFr.setSize (400, 400);
               ObjFr.setVisible (true);
}bakes

Perhaps something like this?
private String tempText = "";
public void actionPerformed(ActionEvent ae) {
if (jTfd.replaceSelection( jbtn.getActionCommand()
) )=="n!") {
          tempText = "";
          long fact=1;
for(int i=1; i<=Integer.parseInt(jTfd.getText());
); i++)
               fact *=i;
          jTfd.setText(String.valueOf(fact));
     else {
tempText +=
+= ((JButton)ae.getSource()).getActionCommand();
          jTfd.replaceSelection(tempText);
           * // Alternately, you can try:
* jTfd.setText(jTfd.getText() +
) + ((JButton)ae.getSource()).getActionCommand());
     }}I tried out what you suggested above but it gave the following eror:
PanFrame.java103:cannot resolve symbol
symbol: variable jbtn
location: class PanFrame
if (jTfd.replaceSelection( jbtn.getActionCommand() )=="n!")
'void' type not allowed here
if (jTfd.replaceSelection( jbtn.getActionCommand() )=="n!")
I do not think "if(jTfd.replaceSelection(jbtn.getActionCommand())=="n!")"
is the correct way of expressing what i intend to archieve. When i first wrote it out it did not make sense to me but i could not find an alternative. so i said let me give it a triy.
i have also attempted to structure it this way
public void actionPerformed(ActionEvent ae)
               JButton jbtn = (JButton)ae.getSource();
               jTfd.replaceSelection( jbtn.getActionCommand() );
               if (ae.getSource()==jbtnFT)
                    int num= Integer.parseInt(jTfd.getText());
                         int i;
                         long fact=1;
                         for(i=1; i<=num; i++)
                                   fact *=i;
                         jTfd.setText(String.valueOf(fact));
          } the action i performed having structured it as stated above was: I pressed the button 5 and it displayed 5 in the textfield then i wanted to find the factorial of 5. so i pressed the (n!) button. instead of calculating the factorial of 5 and displaying the output in the textfield, the factorial symbol was displayed after the number 5 and error messages were displayed in the command prompt. i have tried to type out some of the messages below:
java.lang.NumberFormatException: For input string: "5n!" at java.lang.NumberFormat Exception.forInputString(NumberFormatException.java.48)
at java.lang.Integer.parseInt(Integer.java: 477)
at java.lang.Integer.parseInt(Integer.jaa:518)
at PanFrame.actionPerformed(Drum.java:107)
at javax.swing.AbstractButton.fireActionPerformed (AbstractButton.java:1786)
at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1839)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
Please could you do me favor i am posting the entire code below: copy it and run it then you can see the error messages in its entirety. It is quite lenghty was i tried to type out were jus the first few lines.
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class PanFrame extends JFrame implements ActionListener
     JTextField jTfd =new JTextField(20);
     JButton jbtn7 = new JButton ("7");
     JButton jbtn8 = new JButton ("8");
     JButton jbtn9 = new JButton ("9");
     JButton jbtnFT = new JButton ("n!");
     JButton jbtn4 = new JButton ("4");
     JButton jbtn5 = new JButton ("5");
     JButton jbtn6 = new JButton ("6");
     JButton jbtn1= new JButton ("1");
     JButton jbtn2 = new JButton ("2");
     JButton jbtn3 = new JButton ("3");
     JButton jbtn0 = new JButton ("0");
     public PanFrame (String title)
               super (title);
               Panel pan1 = new Panel();
               getContentPane().setLayout(new FlowLayout ());
               pan1.add(jTfd);
               Panel pan2 = new Panel();
               getContentPane().setLayout (new GridLayout (4,5,2,2));
               pan2.add (jbtn7);
               pan2.add (jbtn8);
               pan2.add (jbtn9);
               pan2.add (jbtnFT);
               pan2.add (jbtn4);
               pan2.add (jbtn5);
               pan2.add (jbtn6);
               pan2.add (jbtn1);
               pan2.add (jbtn2);
               pan2.add (jbtn0);
               getContentPane().add(pan1);
               getContentPane().add(pan2);
               //adding the Listener     
               jTfd.addActionListener(this);
                       jbtn7.addActionListener(this);
               jbtn8.addActionListener(this);
               jbtn9.addActionListener(this);
               jbtnFT.addActionListener(this);
               jbtn4.addActionListener(this);
               jbtn5.addActionListener(this);
               jbtn6.addActionListener(this);
               jbtn1.addActionListener(this);
               jbtn2.addActionListener(this);
               jbtn3.addActionListener(this);
               jbtn0.addActionListener(this);
               validate();
public void actionPerformed(ActionEvent ae)
               JButton jbtn = (JButton)ae.getSource();
               jTfd.replaceSelection( jbtn.getActionCommand() );
               if (ae.getSource()==jbtnFT)
                    int num= Integer.parseInt(jTfd.getText());
                         int i;
                         long fact=1;
                         for(i=1; i<=num; i++)
                                   fact *=i;
                         jTfd.setText(String.valueOf(fact));
public static void main (String arg [ ])
               PanFrame ObjFr = new PanFrame ("Two Panel in One Frame");
               ObjFr.setDefaultCloseOperation(EXIT_ON_CLOSE);
               ObjFr.setSize (400, 400);
               ObjFr.setVisible (true);
}

Similar Messages

  • Urgent-Need help with code for Master data enhancement

    hi Experts,
    I have appended YMFRGR field(Table MARC) to 0MAT_PLANT_ATTR datasource.
    The key fields in the MARC table are MATNR and WERKS.Can anybody help with the user exit to populate this field,as am pretty new to ABAP.
    Thanks in advance

    Hi,
    go through this link which has the similar problem:
    https://forums.sdn.sap.com/click.jspa?searchID=1331543&messageID=2794783
    hope it helps.
    Thanks,
    Amith

  • Need help with code for adding dates to form

    Hello forum goers
    I'm new to making forms and figured out how to auto add the date, however I need the form to change the date for every copy made.
    For example today is 06/08/2012 if I print 10 copies of the form it will output 10 pages ranging from 06/08/2012 to 06/17/2012. If code exists to do this I would be very gratefull to whoever helps, I also wouldn't mind if that is not possible for manually inputing the start / end dates.
    Currently I print 15-30 copies of the form and hand write each of the dates but I'm just getting to busy to do that. I also cannot print one a day it must be in batches.
    Thanks in advanced.

    What you are asking for is more complex than just setting the current date. Each time the form prints it has to know that it has to change the date. I would suggest doing this.
    First, setup a document level script to set the date to the current date. I suspect that you have already done this?
    Next, Create a "DidPrint" document action to increment the date.  To do this the script will need to scan the current text value of the date, add one day to it, and then reformat it.  You'll find information on this type of scripting in these articles:
    http://acrobatusers.com/tutorials/working-with-date-and-time-in-acrobat-javascr
    ipt
    http://acrobatusers.com/tutorials/working-with-date-and-time-in-acrobat-javascr
    ipt-part-2
    http://acrobatusers.com/tutorials/working-with-date-and-time-in-acrobat-javascr
    ipt-part-3
    Since the increment happenes in the Did Print you will need to print each copy individually. If you enter 10 copies in the print dialog it won't work. You have to print one at a time.  You can automate this activity with a console script.
    One of the advantages of incrementing in the DidPrint is that you can also manually enter a date and it will increment from there.
    Thom Parker
    The source for PDF Scripting Info
    pdfscripting.com
    The Acrobat JavaScript Reference, Use it Early and Often
    Then most important JavaScript Development tool in Acrobat
    The Console Window (Video tutorial)
    The Console Window(article)
    Having trouble, Why Doesn't my Script Work?

  • Newbie needing help with code numbers and if-else

    I'm 100% new to any kind of programming and in my 4th week of an Intro to Java class. It's also an on-line class so my helpful resources are quite limited. I have spent close to 10 hours on my class project working out P-code and the java code itself, but I'm having some difficulty because the project seems to be much more advanced that the examples in the book that appear to only be partly directly related to this assignment. I have finally come to a point where I am unable to fix the mistakes that still show up. I'm not trying to get anyone to do my assignment for me, I'm only trying to get some help on what I'm missing. I want to learn, not cheat.
    Okay, I have an assignment that, in a nutshell, is a cash register. JOptionPane prompts the user to enter a product code that represents a product with a specific price. Another box asks for the quanity then displays the cost, tax and then the total amount plus tax, formatted in dollars and cents. It then repeats until a sentinel of "999" is entered, and then another box displays the total items sold for the day, amount of merchandise sold, tax charged, and the total amount acquired for the day. If a non-valid code is entered, I should prompt the user to try again.
    I have this down to 6 errors, with one of the errors being the same error 5 times. Here are the errors:
    C:\PROGRA~1\XINOXS~1\JCREAT~1\MyProjects\Sales.java:50: 'else' without 'if'
    else //if invalid code entered, output message
    ^
    C:\PROGRA~1\XINOXS~1\JCREAT~1\MyProjects\Sales.java:39: unexpected type
    required: variable
    found : value
    100 = 2.98;
    ^
    C:\PROGRA~1\XINOXS~1\JCREAT~1\MyProjects\Sales.java:41: unexpected type
    required: variable
    found : value
    200 = 4.50;
    ^
    C:\PROGRA~1\XINOXS~1\JCREAT~1\MyProjects\Sales.java:43: unexpected type
    required: variable
    found : value
    300 = 6.79;
    ^
    C:\PROGRA~1\XINOXS~1\JCREAT~1\MyProjects\Sales.java:45: unexpected type
    required: variable
    found : value
    400 = 5.29;
    ^
    C:\PROGRA~1\XINOXS~1\JCREAT~1\MyProjects\Sales.java:47: unexpected type
    required: variable
    found : value
    500 = 7.20;
    ^
    And finally, here is my code. Please be gentle with the criticism. I've really put a lot into it and would appreciate any help. Thanks in advance.
    import java.text.NumberFormat; // class for numeric formating from page 178
    import javax.swing.JOptionPane; // class for JOptionOPane
    public class Sales {
    //main method begins execution ofJava Application
    public static void main( String args[] )
    double quantity; // total of items purchased
    double tax; // total of tax
    double value; // total cost of all items before tax
    double total; // total of items including tax
    double totValue; // daily value counter
    double totTax; // daily tax counter
    double totTotal; // daily total amount collected (+tax) counter
    double item; //
    String input; // user-entered value
    String output; // output string
    String itemString; // item code entered by user
    String quantityString; // quantity entered by user
    // initialization phase
    quantity = 0; // initialize counter for items purchased
    // get first code from user
    itemString = JOptionPane.showInputDialog(
    "Enter item code:" );
    // convert itemString to double
    item = Double.parseDouble ( itemString );
    // loop until sentinel value read from user
    while ( item != 999 ) {
    // converting code to amount using if statements
    if ( item == 100 )
    100 = 2.98;
    if ( item == 200 )
    200 = 4.50;
    if ( item == 300 )
    300 = 6.79;
    if ( item == 400 )
    400 = 5.29;
    if ( item == 500 )
    500 = 7.20;
    else //if invalid code entered, output message
    JOptionPane.showMessageDialog( null, "Invalid code entered, please try again!",
    "Item Code", JOptionPane.INFORMATION_MESSAGE );
    } // end if
    } // end while
    // get quantity of item user
    itemString = JOptionPane.showInputDialog(
    "Enter quantity:" );
    // convert quantityString to int
    quantity = Double.parseDouble ( quantityString );
    // add quantity to quantity
    quantity = quantity + quantity;
    // calculation time! value
    value = quantity * item;
    // calc tax
    tax = value * .07;
    // calc total
    total = tax + value;
    //add totals to counter
    totValue = totValue + value;
    totTax = totTax + tax;
    totTotal = totTotal + total;
    // display the results of purchase
    JOptionPane.showMessageDialog( null, "Amount: " + value +
    "\nTax: " + tax + "\nTotal: " + total, "Sale", JOptionPane.INFORMATION_MESSAGE );
    // get next code from user
    itemString = JOptionPane.showInputDialog(
    "Enter item code:" );
    // If sentinel value reached
    if ( item == 999 ) {
    // display the daily totals
    JOptionPane.showMessageDialog( null, "Total amount of items sold today: " + quantity +
    "\nValue of ites sold today: " + totValue + "\nTotal tax collected today: " + totTax +
    "\nTotal Amount collected today: " + totTotal, "Totals", JOptionPane.INFORMATION_MESSAGE );
    System.exit( 0 ); // terminate application
    } // end sentinel
    } // end message
    } // end class Sales

    Here you go. I haven't tested this but it does compile. I've put in a 'few helpful hints'.
    import java.text.NumberFormat; // class for numeric formating from page 178
    import javax.swing.JOptionPane; // class for JOptionOPane
    public class TestTextFind {
    //main method begins execution ofJava Application
    public static void main( String args[] )
         double quantity; // total of items purchased
         double tax; // total of tax
         double value; // total cost of all items before tax
         double total; // total of items including tax
    //     double totValue; // daily value counter
    //     double totTax; // daily tax counter
    //     double totTotal; // daily total amount collected (+tax) counter
    // Always initialise your numbers unless you have a good reason not too
         double totValue = 0; // daily value counter
         double totTax = 0; // daily tax counter
         double totTotal = 0; // daily total amount collected (+tax) counter
         double itemCode;
         double item = 0;
         String itemCodeString; // item code entered by user
         String quantityString; // quantity entered by user
         // initialization phase
         quantity = 0; // initialize counter for items purchased
         // get first code from user
         itemCodeString = JOptionPane.showInputDialog("Enter item code:" );
         // convert itemString to double
         itemCode = Double.parseDouble ( itemCodeString );
         // loop until sentinel value read from user
         while ( itemCode != 999 ) {
    * 1. variable item mightnot have been initialised
    * You had item and itemCode the wrong way round.
    * You are supposed to be checking itemCode but setting the value
    * for item
              // converting code to amount using if statements
              if ( item == 100 )
              {itemCode = 2.98;}
              else if ( item == 200 )
              {itemCode = 4.50;}
              else if ( item == 300 )
              {itemCode = 6.79;}
              else if ( item == 400 )
              {itemCode = 5.29;}
              else if ( item == 500 )
              {itemCode = 7.20;}
              else {//if invalid code entered, output message
                   JOptionPane.showMessageDialog( null, "Invalid code entered, please try again!",
                   "Item Code", JOptionPane.INFORMATION_MESSAGE );
              } // end if
         } // end while
         // get quantity of item user
         itemCodeString = JOptionPane.showInputDialog("Enter quantity:" );
    * 2.
    * You have declared quantityString here but you never give it a value.
    * I think this should be itemCodeString shouldnt it???
    * Or should you change itemCodeString above to quantityString?
         // convert quantityString to int
    //     quantity = Double.parseDouble ( quantityString );  // old code
         quantity = Double.parseDouble ( itemCodeString );
         // add quantity to quantity
         quantity = quantity + quantity;
         // calculation time! value
         value = quantity * itemCode;
         // calc tax
         tax = value * .07;
         // calc total
         total = tax + value;
         //add totals to counter
    * 3. 4. and 5.
    * With the following you have not assigned the 'total' variables a value
    * so in effect you are saying eg. "total = null + 10". Thats why an error is
    * raised.  If you look at your declaration i have assigned them an initial
    * value of 0.
         totValue = totValue + value;
         totTax = totTax + tax;
         totTotal = totTotal + total;
         // display the results of purchase
         JOptionPane.showMessageDialog( null, "Amount: " + value +
         "\nTax: " + tax + "\nTotal: " + total, "Sale", JOptionPane.INFORMATION_MESSAGE );
         // get next code from user
         itemCodeString = JOptionPane.showInputDialog("Enter item code:" );
         // If sentinel value reached
         if ( itemCode == 999 ) {
              // display the daily totals
              JOptionPane.showMessageDialog( null, "Total amount of items sold today: " + quantity +
              "\nValue of ites sold today: " + totValue + "\nTotal tax collected today: " + totTax +
              "\nTotal Amount collected today: " + totTotal, "Totals",           JOptionPane.INFORMATION_MESSAGE );
              System.exit( 0 ); // terminate application
         } // end sentinel
    } // end message
    } // end class SalesRob.

  • Need help with code

    Hi,
    I'm new to java, i'm creating java analog clock application. but i'm getting so many errors. i still try to figur out what are those. can someone please help me with this code. Thank you
    here is my code
    import java.awt.*;
    import java.awt.event.*;
    import java.util.*;
    import java.text.*;
    import javax.swing.*;
    //The main class
    public class AnalogClock extends JFrame
    // Initialize all the variables
    SimpleDateFormat f_s = new SimpleDateFormat ("ss", Locale.getDefault());
    SimpleDateFormat f_m = new SimpleDateFormat ("mm", Locale.getDefault());
    SimpleDateFormat f_h = new SimpleDateFormat ("hh", Locale.getDefault());
    SimpleDateFormat standard = new SimpleDateFormat ("HH:mm:ss", Locale.getDefault());
    int xs, ys, xm, ym, xh, yh, s, xcenter, ycenter, m, h, x, y, mouse_x, mouse_y;
    String temp;
    Dimension d;
    Date now;
    Thread thr = null;
    Image im;
    Boolean M = false;
    Graphics gIm;
    Dimension dIm;
    int sx, sy, sx2, sy2;
    Color digital = Color.blue, hour = Color.blue, minute = Color.yellow,
    second = Color.green, circle = Color.red, hours = Color.blue, mute_logo = Color.green;
    // paint(): the main part of the program
    public void paint(Graphics g)
    d = getSize();
    xcenter = d.width/2;
    ycenter = d.height/2;
    x = d.width;
    y = d.height;
    if(im == null)
    im = createImage(x, y);
    gIm = im.getGraphics();
    dIm = new Dimension(x, y);
    // Get the current timestamp
    now = new Date();
    // Get the seconds
    temp = f_s.format(now);
    s = Integer.parseInt(temp);
    temp = f_m.format(now);
    m = Integer.parseInt(temp);
    temp = f_h.format(now);
    h = Integer.parseInt(temp);
    // Calculate all the positions of the hands
    xs = (int) (Math.cos(s * Math.PI / 30 - Math.PI / 2) * 45 + xcenter);
    ys = (int) (Math.sin(s * Math.PI / 30 - Math.PI / 2) * 45 + ycenter);
    xm = (int) (Math.cos(m * Math.PI / 30 - Math.PI / 2) * 40 + xcenter);
    ym = (int) (Math.sin(m * Math.PI / 30 - Math.PI / 2) * 40 + ycenter);
    xh = (int) (Math.cos((h * 30 + m / 2) * Math.PI / 180 - Math.PI / 2) * 30 + xcenter);
    yh = (int) (Math.sin((h * 30 + m / 2) * Math.PI / 180 - Math.PI / 2) * 30 + ycenter);
    // Refresh the image
    gIm.setColor(getBackground());
    gIm.fillRect(0, 0, dIm.width, dIm.height);
    // Draw the circle of the clock
    gIm.setColor(circle);
    gIm.drawOval(0, 0, d.width-1, d.height-1);
    gIm.setColor(hours);
    // Draw the stripes of the hours
    for(int i = 0;i<12;i++)
    sx = (int) (Math.cos((i * 30) * Math.PI / 180 - Math.PI / 2) * 47 + xcenter);
    sy = (int) (Math.sin((i * 30) * Math.PI / 180 - Math.PI / 2) * 47 + xcenter);
    sx2 = (int) (Math.cos((i * 30) * Math.PI / 180 - Math.PI / 2) * 49 + xcenter);
    sy2 = (int) (Math.sin((i * 30) * Math.PI / 180 - Math.PI / 2) * 49 + xcenter);
    gIm.drawLine(sx, sy, sx2, sy2);
    // Draw the time on the top of the clock
    gIm.setColor(digital);
    gIm.drawString(standard.format(now), 25, 30);
    // Draw the mute logo
    Mute m = new Mute(M, gIm);
    // Draw the hands
    // Seconds
    gIm.setColor(second);
    gIm.drawLine(xcenter, ycenter, xs, ys);
    // Minutes
    gIm.setColor(minute);
    gIm.drawLine(xcenter, ycenter-1, xm, ym);
    gIm.drawLine(xcenter-1, ycenter, xm, ym);
    // Hour
    gIm.setColor(hour);
    gIm.drawLine(xcenter, ycenter-1, xh, yh);
    gIm.drawLine(xcenter-1, ycenter, xh, yh);
    // Paint the generated image on the screen
    if(im != null)
    g.drawImage(im, 0, 0, null);
    if(M == false)
    play(getCodeBase(), "Sound/Click.wav");
    public void update(Graphics g)
    paint(g);
    class Mute
    Mute(Boolean mute, Graphics g)
    g.setColor(mute_logo);
    Polygon p = new Polygon();
    p.addPoint(1, 7);
    p.addPoint(6, 2);
    p.addPoint(6, 12);
    g.fillPolygon(p);
    g.drawLine(7, 5, 7, 9);
    g.drawLine(9, 4, 9, 10);
    g.drawLine(11, 3, 11, 11);
    if(mute == true)
    g.drawLine(13, 3, 1, 11);
    /* // All the mouse events
    public void mousePressed(MouseEvent evt)
    mouse_x = evt.getX();
    mouse_y = evt.getY();
    if(mouse_x <= 11 && mouse_x >= 1 && mouse_y <= 12 && mouse_y >= 2)
    if(M == true)
    M = false;
    } else {
    M = true;
    repaint();
    public void mouseReleased(MouseEvent evt){}
    public void mouseEntered(MouseEvent evt){}
    public void mouseExited(MouseEvent evt){}
    public void mouseClicked(MouseEvent evt){}
    }

    There is a gross misconception among the new and learning programmers that a lot of code is good and once you put that last close scope in place that things are wonderful because you have all the code down...
    Please repeat this: NO, short debugged runs and incremental builds are better.
    As a matter of fact, that is so important, go back and say it again and again until it really truly sinks in.
    This concept is really pounded into your soul when you program in assembler--probably an ailment of the new generation of programmers, they never have had to do assembler or machine coding--but any time you get more than about 20 lines of code that hasn't been checked for bugs, you should start thinking... "Oh, do I really have the skills and patience to go back and debug (yes, actually use the debugger to step through it all.) that big of mess?" The biggest project is just like eating an elephant, you do it one small bite at a time over as long a time as it takes--you don't cook half the elephant and sit down and expect to eat it in one meal; neither do you sit down and decide to code a whole program and then debug it. You just don't have the skill to do it.
    When you modify someone else's code, the same is true--small changes and debug as you change. Making all the changes you want, then debugging just runs into a huge error file of related problems that are basically indiscernible from each other because many of them are probably related.
    Most of the request for "Help, I cannot get this to run." Also contain the words: "I just finished coding..." That statement in and of itself is one of the great flawed concepts that anyone can have--coding is complete when you have an acceptable release candidate, and then only until you decide or are asked to make further changes.
    Work in small blocks of code and incrementally build a project--your frustration levels will be much less. And as you gain skill, increase the size of the code blocks (I had a friend in college that never had 5 consecutive lines of code compile--ever! He works for MS now.) and get to know your debugger. Your debugger is your friend, if you've not been introduced to your debugger, then get acquainted soon! Like maybe before you even try to cut another piece of code.
    On the other side of things... cheer up, we've all been there and learned the lessons... some lessons just come harder than others... make your life less frustrating, it's a lot more fun and enjoyable.

  • SSL - Default SSL context init failed: null - need help with code

    Hi!
    Once Again I have problems with SSL.
    I read something about SSL here:
    http://www.javaalmanac.com/egs/javax.net.ssl/Server.html
    Now I tried to test this stuff, that resulted in this program (I simply tried to put the SSL stuff from the above code in a small skeleton):
    import java.io.*;
    import java.net.*;
    import java.security.*;
    import javax.net.ssl.*;
    import javax.net.*;
    public class MyServer
         public static void main(String arguments[])
         try
              int port = 443;
              ServerSocketFactory ssocketFactory = SSLServerSocketFactory.getDefault();
              ServerSocket ssocket = ssocketFactory.createServerSocket(port);
              // Listen for connections
              Socket socket = ssocket.accept();
              System.out.println("Connected successfully");
              // Create streams to securely send and receive data to the client
              InputStream in = socket.getInputStream();
              OutputStream out = socket.getOutputStream();
              // Read from in and write to out...
              // Close the socket
              in.close();
              out.close();
         catch(IOException e)
              System.out.println("GetMessage() = "+e.getMessage());
              e.printStackTrace();
    }     Now I compiled this stuff with : 'javac MyServer.java' - there were no errors. After this I run the program
    with the following command (also taken from java almanac):
    'java -Djavax.net.ssl.keyStore=mySrvKeystore -Djavax.net.ssl.keyStorePassword=123456 MyServer'
    But if I run it, it reports:
    "GetMessage() = Default SSL context init failed: null
    java.net.SocketException: Default SSL context init failed: null
    at javax.net.ssl.DefaultSSLServerSocketFactory.createServerSocket(Dasho
    6275)
    at MyServer.main(MyServer.java:15)"
    createServerSocket() seems to be the wrong line, but what is wrong with it.
    Is there any mistake in my code ?
    Btw. I created my keystore etc. according to the instructions at
    http://forum.java.sun.com/thread.jsp?forum=2&thread=528092&tstart=0&trange=15
    Any help appreciated
    Greets
    dancing_coder

    I got this error last week.
    The problem was that the keystore I was pointing to, was in other location, so it could not initialize the default context.
    I had defined ...
    String CLIENT_CERTIFPATH = getParam("client.certificate.path", "/users/pridas/myKeystoreFile");
    // getParam extracts the location of the keystore from a text file which contains some configuration parameters. The default value will be /users/pridas/myKeystoreFile
    In my case, I will try to develop a secure SOAP conexion using certificates.
    Before to try the conexion, I defined ...
    System.setProperty("javax.net.ssl.trustStore", CLIENT_CERTIFPATH);
    System.setProperty("javax.net.ssl.keyStore", CLIENT_CERTIFPATH);
    ... and the problem when I got this error ... the keystore file was not in the correct location.
    That was how I resolved this error.
    I hope everybody will be oriented about this kind of errors.
    Salu2.

  • Video Producer needs help with code error

    Hi all!
    At the risk of getting long winded, I am a video producer who
    has in the last 6 months gotten into web development for myself and
    to offer to clients.
    I am in the process of learning DreamWeaver and like it very
    much, but I must say that the worlds of web development and video
    production are extremely different and in some ways, building a
    website is far more difficult. I have because of this, a new found
    respect for good web developers as they are worth their weight in
    gold.
    My problem today is that I added a second Quicktime video in
    the index page of an already existing site of my own and this video
    will not show up. It just displays the QT logo.
    Is someone willing to look at the code and maybe offer an
    explanation of what I am doing wrong? The site is
    www.coosbaytv.com. The issue is on the homepage and very apparent
    when you scroll to the lower half of the page. The first video is
    fine, the second (D'S MEDI-TANZ) is not.
    I am completely stumped and need to get this resolved.
    Thanks, Jay

    <I have... a new found respect for good web developers as
    they are worth
    their weight in gold.>
    You betcha! I wish everyone felt that way.
    http://www.coosbaytv.com/medi-tanz.mov
    Page cannot be found.
    Upload your QT movie to the server.
    --Nancy O.
    Alt-Web Design & Publishing
    www.alt-web.com
    "coosbaytv" <[email protected]> wrote in
    message
    news:fc1c1v$rmv$[email protected]..
    > Hi all!
    >
    > At the risk of getting long winded, I am a video
    producer who has in the
    last
    > 6 months gotten into web development for myself and to
    offer to clients.
    > I am in the process of learning DreamWeaver and like it
    very much, but I
    must
    > say that the worlds of web development and video
    production are extremely
    > different and in some ways, building a website is far
    more difficult. I
    have
    > because of this, a new found respect for good web
    developers as they are
    worth
    > their weight in gold.
    >
    > My problem today is that I added a second Quicktime
    video in the index
    page of
    > an already existing site of my own and this video will
    not show up. It
    just
    > displays the QT logo.
    >
    > Is someone willing to look at the code and maybe offer
    an explanation of
    what
    > I am doing wrong? The site is www.coosbaytv.com. The
    issue is on the
    homepage
    > and very apparent when you scroll to the lower half of
    the page. The first
    > video is fine, the second (D'S MEDI-TANZ) is not.
    >
    > I am completely stumped and need to get this resolved.
    >
    > Thanks, Jay
    >

  • Need help with code not displaying on the Stage:(

    // The following code is for a puzzle i'm trying to create, but it doesn't seem to want to display:
    stop();
              import flash.display.stage;
        import flash.events.stage;
        import flash.text.stage;
        import flash.utils.stage;
    var solve_btn:SimpleButton;
    var myFormat:TextFormat;
    var theSolution:Array;
    var visualGrid:Array;
    var showSolutionTimer:Timer;
    var s:Sudoku;
    var iGridUnsolved:Array;
    var showSolutionStepsOrder:Array;
            function Solution()
                addFrameScript(0,frame1);
                return;
            }// end function
    function randomSort(param1, param2:Object) : int
                return 1 - Math.floor(Math.random() * 3);
            }// end function
            function createGrid() : void
                var location_2:TextField = null;
                var location_1:int = 0;
                while (location_1 < 81)
                    location_2 = new TextField();
                    location_2.x = Math.floor(location_1 / 9) * 67 + 108;
                    location_2.y = location_1 % 9 * 57 + 48 + 20;
                    location_2.width = 60;
                    location_2.height = 53;
                    location_2.defaultTextFormat = myFormat;
                    if (iGridUnsolved[location_1] != 0)
                        location_2.text = iGridUnsolved[location_1];
                    visualGrid.push(location_2);
                    this.addChild(location_2);
                    showSolutionStepsOrder.push(location_1);
                    location_1++;
                showSolutionStepsOrder.sort(randomSort);
                                  return;
            }// end function
            function frame1()
                s = new Sudoku();
                iGridUnsolved = new Array(3, 5, 0, 4, 6, 0, 2, 0, 0, 6, 0, 0, 1, 0, 2, 0, 4, 0, 0, 1, 0, 3, 0, 0, 0, 7, 8, 0, 0, 4, 0, 1, 8, 5, 0, 7, 0, 6, 5, 0, 0, 0, 9, 8, 0, 0, 0, 7, 6, 5, 0, 1, 0, 0, 7, 8, 0, 0, 0, 6, 0, 2, 0, 0, 2, 0, 8, 0, 9, 0, 0, 3, 0, 0, 0, 0, 7, 1, 0, 5, 6);
                visualGrid = new Array();
                myFormat = new TextFormat();
                myFormat.color = 000000;
                myFormat.font = "Arial";
                myFormat.size = 24;
                myFormat.align = TextFormatAlign.CENTER;
                showSolutionStepsOrder = new Array();
                createGrid();
                theSolution = s.solve(iGridUnsolved);
                showSolutionTimer = new Timer(90);
                showSolutionTimer.start();
                showSolutionTimer.addEventListener(TimerEvent.TIMER, showStep);
                                  solve_btn.addEventListener(MouseEvent.CLICK, Start);
                return;
            }// end function
            function showStep(event:TimerEvent) : void
                var location_2:* = showSolutionStepsOrder.pop();
                var location_3:* = theSolution[location_2];
                var location_4:* = new TextFormat();
                new TextFormat().color = 0;
                if (visualGrid[location_2].text.length == 0)
                    visualGrid[location_2].text = location_3;
                    visualGrid[location_2].setTextFormat(location_4);
                if (showSolutionStepsOrder.length == 0)
                    showSolutionTimer.stop();
                event.updateAfterEvent();
                return;
            }// end function
    // Its probably something really small, just can't figure it out myself.

    Not sure why you are using addFrameScript() - try just calling the funcion, i.e. replace this
    function Solution()
        addFrameScript(0,frame1);
        return;
    }// end function
    with this
    frame1();
    Kenneth Kawamoto
    http://www.materiaprima.co.uk/

  • NEED HELP with T400s ThinkPad, does not work!!

    Hey guys I'm new to this forum.
    Basically I purchased a T400s laptop 4 years ago and have been using it throughout college. Recently I have been having MANY issues and I can't pinpoint the hardware/software problem.
    It constantly overheats, TPfancontrol was able to moderate it for a while but now it is just rediculous. When I click on any application (ie internet explorer) it takes up to 30 seconds to respond, during those 30 seconds the computer would 'freeze'. I am unable to use it now. I tried running a HD diagnostic test but the computer overheated and shutdown before the test could complete.
    A friend has told me that it is probably a HD and RAM problem and that I should upgrade both. At this point I am wondering if I should just buy a new laptop.. I don't have the time to constantly try to fix this laptop and do not have $500 to send it in to get fixed with the risk of it happening again. Any ideas what this problem might be? PLEASE HELP!

    well overheating could be one issue.
    But given that your laptop is really slow even at the boot up, it could mean something else.
    Can you run a hdd diagnostic from your BIOS menu?
    Regards,
    Jin Li
    May this year, be the year of 'DO'!
    I am a volunteer, and not a paid staff of Lenovo or Microsoft

  • Need helps with getting ODI CDC to work

    Hi, I'm new to ODI. I'm trying to get the ODI CDC to work and for now I'm only interested in seeing that the changes are captured correctly.
    I've set the d/b to archivelog mode and granted all the rights I can think of to the d/b user. I've defined the CDC in Consistent Mode for the model, defined the CDC for my tables, started the journal, etc.
    When I right-click on the table and do Change Data Capture/Journal Data... I get ORA-00904 Table or View not found (stack trace below)
    What is missing? Thanks for your assistance.
    See com.borland.dx.dataset.DataSetException error code: BASE+62
    com.borland.dx.dataset.DataSetException: Execution of query failed.
         at com.borland.dx.dataset.DataSetException.a(Unknown Source)
         at com.borland.dx.dataset.DataSetException.queryFailed(Unknown Source)
         at com.borland.dx.sql.dataset.QueryProvider.a(Unknown Source)
         at com.borland.dx.sql.dataset.JdbcProvider.provideData(Unknown Source)
         at com.borland.dx.dataset.StorageDataSet.refresh(Unknown Source)
         at com.borland.dx.sql.dataset.QueryDataSet.refresh(Unknown Source)
         at com.sunopsis.graphical.frame.a.jb.dj(jb.java)
         at com.sunopsis.graphical.frame.a.jb.<init>(jb.java)
         at com.sunopsis.graphical.frame.a.jd.<init>(jd.java)
         at com.sunopsis.graphical.frame.a.je.<init>(je.java)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
         at java.lang.reflect.Constructor.newInstance(Unknown Source)
         at com.sunopsis.graphical.frame.bb.b(bb.java)
         at com.sunopsis.graphical.tools.utils.swingworker.v.call(v.java)
         at edu.emory.mathcs.backport.java.util.concurrent.FutureTask.run(FutureTask.java:176)
         at com.sunopsis.graphical.tools.utils.swingworker.l.run(l.java)
         at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:665)
         at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:690)
         at java.lang.Thread.run(Unknown Source)
    Chained exception:
    java.sql.SQLException: ORA-00942: table or view does not exist
         at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:316)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:282)
         at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:639)
         at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:185)
         at oracle.jdbc.driver.T4CPreparedStatement.execute_for_describe(T4CPreparedStatement.java:503)
         at oracle.jdbc.driver.OracleStatement.execute_maybe_describe(OracleStatement.java:965)
         at oracle.jdbc.driver.T4CPreparedStatement.execute_maybe_describe(T4CPreparedStatement.java:535)
         at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1051)
         at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:2984)
         at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:3026)
         at com.borland.dx.sql.dataset.o.f(Unknown Source)
         at com.borland.dx.sql.dataset.QueryProvider.e(Unknown Source)
         at com.borland.dx.sql.dataset.JdbcProvider.provideData(Unknown Source)
         at com.borland.dx.dataset.StorageDataSet.refresh(Unknown Source)
         at com.borland.dx.sql.dataset.QueryDataSet.refresh(Unknown Source)
         at com.sunopsis.graphical.frame.a.jb.dj(jb.java)
         at com.sunopsis.graphical.frame.a.jb.<init>(jb.java)
         at com.sunopsis.graphical.frame.a.jd.<init>(jd.java)
         at com.sunopsis.graphical.frame.a.je.<init>(je.java)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
         at java.lang.reflect.Constructor.newInstance(Unknown Source)
         at com.sunopsis.graphical.frame.bb.b(bb.java)
         at com.sunopsis.graphical.tools.utils.swingworker.v.call(v.java)
         at edu.emory.mathcs.backport.java.util.concurrent.FutureTask.run(FutureTask.java:176)
         at com.sunopsis.graphical.tools.utils.swingworker.l.run(l.java)
         at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:665)
         at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:690)
         at java.lang.Thread.run(Unknown Source)
    java.sql.SQLException: ORA-00942: table or view does not exist
         at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:316)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:282)
         at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:639)
         at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:185)
         at oracle.jdbc.driver.T4CPreparedStatement.execute_for_describe(T4CPreparedStatement.java:503)
         at oracle.jdbc.driver.OracleStatement.execute_maybe_describe(OracleStatement.java:965)
         at oracle.jdbc.driver.T4CPreparedStatement.execute_maybe_describe(T4CPreparedStatement.java:535)
         at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1051)
         at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:2984)
         at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:3026)
         at com.borland.dx.sql.dataset.o.f(Unknown Source)
         at com.borland.dx.sql.dataset.QueryProvider.e(Unknown Source)
         at com.borland.dx.sql.dataset.JdbcProvider.provideData(Unknown Source)
         at com.borland.dx.dataset.StorageDataSet.refresh(Unknown Source)
         at com.borland.dx.sql.dataset.QueryDataSet.refresh(Unknown Source)
         at com.sunopsis.graphical.frame.a.jb.dj(jb.java)
         at com.sunopsis.graphical.frame.a.jb.<init>(jb.java)
         at com.sunopsis.graphical.frame.a.jd.<init>(jd.java)
         at com.sunopsis.graphical.frame.a.je.<init>(je.java)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
         at java.lang.reflect.Constructor.newInstance(Unknown Source)
         at com.sunopsis.graphical.frame.bb.b(bb.java)
         at com.sunopsis.graphical.tools.utils.swingworker.v.call(v.java)
         at edu.emory.mathcs.backport.java.util.concurrent.FutureTask.run(FutureTask.java:176)
         at com.sunopsis.graphical.tools.utils.swingworker.l.run(l.java)
         at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:665)
         at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:690)
         at java.lang.Thread.run(Unknown Source)

    Update...
    I traced it to the Start Journal step issue. The Operator shows that step 8 - Journalizing - xxxx - Create Change Set, produces Oracle error ORA-00600. What does this means? The SQL that it tries to execute is:
    ==============================================
    BEGIN
         DBMS_CDC_PUBLISH.CREATE_CHANGE_SET(
         change_set_name     => 'TID_SOURCE',
         description     => 'Sunopsis change set for model : TID_SOURCE',
         change_source_name     => 'HOTLOG_SOURCE',
         begin_date     => sysdate
    END;
    ==============================================
    The strack trace is as follows:
    600 : 60000 : java.sql.SQLException: ORA-00600: internal error code, arguments: [kcbgcur_9], [8388665], [23], [25165824], [8388608], [], [], []
    ORA-06512: at "SYS.DBMS_CAPTURE_ADM_INTERNAL", line 121
    ORA-06512: at line 1
    ORA-06512: at "SYS.DBMS_CDC_PUBLISH", line 560
    ORA-06512: at line 1
    java.sql.SQLException: ORA-00600: internal error code, arguments: [kcbgcur_9], [8388665], [23], [25165824], [8388608], [], [], []
    ORA-06512: at "SYS.DBMS_CAPTURE_ADM_INTERNAL", line 121
    ORA-06512: at line 1
    ORA-06512: at "SYS.DBMS_CDC_PUBLISH", line 560
    ORA-06512: at line 1
         at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:316)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:282)
         at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:639)
         at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:185)
         at oracle.jdbc.driver.T4CPreparedStatement.execute_for_rows(T4CPreparedStatement.java:633)
         at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1086)
         at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:2984)
         at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:3057)
         at com.sunopsis.sql.SnpsQuery.executeUpdate(SnpsQuery.java)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.execStdOrders(SnpSessTaskSql.java)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTaskTrt(SnpSessTaskSql.java)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSqlC.treatTaskTrt(SnpSessTaskSqlC.java)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java)
         at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java)
         at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java)
         at com.sunopsis.dwg.cmd.DwgCommandSession.treatCommand(DwgCommandSession.java)
         at com.sunopsis.dwg.cmd.DwgCommandBase.execute(DwgCommandBase.java)
         at com.sunopsis.dwg.cmd.e.i(e.java)
         at com.sunopsis.dwg.cmd.g.y(g.java)
         at com.sunopsis.dwg.cmd.e.run(e.java)
         at java.lang.Thread.run(Unknown Source)

  • HT4113 I need help with getting my phoe to work.

    I forgot my password to my phone yesterday, and it's telling my to connect to iTunes and I did, but itunes is telling me that I have a problem and it's not letting me put it on recovory mode. Do you think you could help me?

    What is the EXACT error message you're getting?

  • Need help with saving Premiere files to work with any update

    Hey everybody,
    I've been editing with Premiere for a while now and I haven't really had too many issues until now. I live on campus at school and they just opened up a new Library with extensive Mac Pro editing stations, some with 4K monitors! The problem is that the school is not updating the software. So I am running the latest version on my Macbook Pro, but when I try and open the files on the library computers, it tells me something like, "Cannot open file because file was saved on a newer version." Now I know it seems obvious that I should just stick to my computer, but it's nice having a much faster editing station with 27"+ screens. Because the library is so new, they are having trouble keeping up with all the updates and they don't seem to plan on updating them except every semester. So, are there any workarounds? Can I save my files as a more multi-platform file?

    I would take your computer back to the earlier version the college uses, there are workarounds to go back versions but they are not perfect.

  • Need help with a activation code for Adobe Acrobat X Standard for my PC,, Don't have older version serial numbers,  threw programs away,  only have Adobe Acrobat X Standard,  need a code to unlock program?

    Need help with a activation code for Adobe Acrobat X Standard for my PC, Don't have older Version of Adobe Acrobat 9, 8 or 7. 

    You don't need to install the older version, you only need the serial number from your original purchase. If you don't have them to hand, did you register? If so, they should be in your Adobe account. If not you really need to contact Adobe, though it isn't clear they will be able to do anything without some proof of purchase etc.

  • Need Help With Simple ABAP Code

    Hello,
    I'm loading data from a DSO (ZDTBMAJ) to an Infocube (ZCBRAD06). I need help with ABAP code to some of the logic in Start Routine. DSO has 2 fields: ZOCTDLINX & ZOCBRDMAJ.
    1. Need to populate ZOCPRODCD & ZOCREFNUM fields in Infocube:
        Logic:-
        Lookup /BI0/PMATERIAL, if /BIC/ZOCBRDMAJ = /BIC/OIZOCBRDMAJ
        then /BIC/ZOCPRODCD = ZOCPRODCD in Infocube
               /BIC/ZOCREFNUM = ZOCREFNUM in Infocube         
    2. Need to populate 0G_CWWTER field in Infocube:
        Logic:
        Lookup /BIC/PZOCTDLINX, if /BIC/ZOCTDLINX = BIC/OIZOCTDLINX
        then G_CWWTER = 0G_CWWTER in Infocube.
    I would need to read single row at a time.
    Thanks!

    I resolved it.

  • I need help with this code error "unreachable statement"

    the error_
    F:\Java\Projects\Tools.java:51: unreachable statement <-----------------------------------------------------------------------------------------------------------------THIS
    int index;
    ^
    F:\Java\Projects\Tools.java:71: missing return statement
    }//end delete method
    ^
    F:\Java\Projects\Tools.java:86: missing return statement
    }//end getrecod
    ^
    3 errors
    import java.util.*;
    import javax.swing.*;
    import java.awt.*;
    public class Tools//tool class
    private int numberOfToolItems;
    private ToolItems[] toolArray = new ToolItems[10];
    public Tools()//array of tool
    numberOfToolItems = 0;
    for(int i = 0; i < toolArray.length; i++)//for loop to create the array tools
    toolArray[i] = new ToolItems();
    }//end for loop
    }//end of array of tools
    public int search(int id)//search mehtod
    int index = 0;
    while (index < numberOfToolItems)//while and if loop search
    if(toolArray[index].getID() == id)
    return index;
    else
    index ++;
    }//en while and if loop
    return -1;
    }//end search method
    public int insert(int id, int numberInStock, int quality, double basePrice, String nm)//insert method
    if(numberOfToolItems >= toolArray.length)
    return 0;
    int index;
    index = search(id); <-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------HERE
    if (index == -1)
    toolArray[index].assign(id,numberInStock, quality, basePrice,nm);
    numberInStock ++;
    return 1;
    }//end if index
    }//end if toolitem array
    return -1;
    }//end insert method
    public int delete(/*int id*/)//delete method
    }//end delete method
    public void display()//display method
    for(int i = 0; i < numberOfToolItems; i++)
    //toolArray.display(g,y,x);
    }//end display method
    public String getRecord(int i)//get record method
    // return toolArray[i].getName()+ "ID: "+toolArray[i].getID()
    }//end getrecod
    }//end class
    Edited by: ladsoftware on Oct 9, 2009 6:08 AM
    Edited by: ladsoftware on Oct 9, 2009 6:09 AM
    Edited by: ladsoftware on Oct 9, 2009 6:10 AM
    Edited by: ladsoftware on Oct 9, 2009 6:11 AM

    ladsoftware wrote:
    Subject: Re: I need help with this code error "unreachable statement"
    F:\Java\Projects\Tools.java:51: unreachable statement <-----------------------------------------------------------------------------------------------------------------THIS
    int index;
    ^
    F:\Java\Projects\Tools.java:71: missing return statement
    }//end delete method
    ^
    F:\Java\Projects\Tools.java:86: missing return statement
    }//end getrecod
    ^
    3 errorsThe compiler is telling you exactly what the problems are:
    public int insert(int id, int numberInStock, int quality, double basePrice, String nm)//insert method
    if(numberOfToolItems >= toolArray.length)
    return 0; // <<== HERE you return, so everyting in the if block after this is unreachable
    int index;
    index = search(id);  //< -----------------------------------------------------------------------------------------------------------------HERE
    if (index == -1)
    toolArray[index].assign(id,numberInStock, quality, basePrice,nm);
    numberInStock ++;
    return 1;
    }//end if index
    }//end if toolitem array
    return -1;
    }//end insert method
    public int delete(/*int id*/)//delete method
    // <<== HERE where is the return statement?
    }//end delete method
    public String getRecord(int i)//get record method
    // return toolArray.getName()+ "ID: "+toolArray[i].getID() <<== HERE you commented out the return statement
    }//end getrecod
    }//end class

Maybe you are looking for

  • HT5834 can't turn off iCloud keychain on apple devices and can't get them to sync !

    i could gey my apple devices to sync icloud keychains , nor could i get them to turn off icloud key chain. Solution: Reset icloud keycahin using forgot passcode option, it will reset the entire icloud keycahin and bring every thing back to the way it

  • Adapter Message Based Partitioning

    Hi, I'm trying to investigate the use of partitioning without much success. I have set up two publishing AQ adapters with a partition created on both, routing event1 via first partition (on adapter1) and routing event2 via the second partition (on ad

  • The question about BBPGETVD

    Hi, all Please help me, I have 2 backend systems, and I want to transfer through trx. BBPGETVD the vendor: First backend system - 16008 "Country System", Second backend system - 16008 "Permoil". May I to transfer through trx. BBPGETVD two vendor from

  • TS4223 i want to buy and HD movie but only show in SD on my appletv (ie: Wreck it Ralph)

    Say I buy an early release movie in HD, but my bandwidth at home is ok, but several people share it, so on my AppleTV I want the SD version to stream and not HD, how do I do this?

  • Elliptic Curve

    Hi to all, i'm an italian student and i must implements the BLS signature scheme in Java. BLS work on elliptic curve over finite field F3^m. I've seen elliptic curve in Java but over finite field F2^m. The question is: how i can do? Excuse me for my