GUI Calculator

Hello everyone! I'm trying to create a GUI Calculator but cannot get my program to compile. Please could someone assist me, thanks.
import java.io.*;
import java.util.*;
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
public class CalculatorFrame extends JFrame
private Container contentPane;
//The componenets used in the calculator
private JTextField display;
private JButton addition;
private JButton subtract;
private JButton multiply;
private JButton divide;
private JButton mod;
private JButton enter;
private JButton [] digits;
//End of components
//Integer representations for the arithmetic operations needed
private final static int ADD = 1;
private final static int SUB = 2;
private final static int MUL = 3;
private final static int DIV = 4;
private final static int MOD = 5;
//ENd of arithmethic operations
//Integer holding the operator that the user requested
private int op;
//Boolean variable to help perform the calculations
private boolean firstFilled;
private boolean clearScreen;
//Constructor for the class
public CalculatorFrame()
contentPane=new Container();
this.setSize(400,300); //sets the size of the frame
this.setTitle("MIS 222 Calculator"); //sets the title of the frame
//allows the "X" box in the upper right hand corner to close the entire application
this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
contentPane=this.getContentPane(); //gets the content pane
//Methods
addDisplay();
addDigits();
addDigitActionListeners();
addOperation();
private void addDisplay()
JLabel displayLab = new JLabel("Answer");
JPanel north = new JPanel();
north.add(displayLab);
contentPane.add(north, "North");
//diplay was already declared above the constructor
display = new JTextField(25);
//adding the components to the panel
north.add(displayLab);
north.add(display);
//adding the panel to frame's content pane
contentPane.add(north, "North");
//Declaring the global digits array
private void addDigits()
//Add 1 large panel to hold the 3 inner panels
JPanel digPanel = new JPanel();
//Set the panel's preferred size so that it will keep everything in line
digPanel.setPreferredSize(new Dimension(200, 275));
//Initialize the top 3 digits' JPanel and set its preferrd size
JPanel topDigits = new JPanel();
topDigits.setPreferredSize(new Dimension(200,60));
//Initialize the middle 2 digits' JPanel and set its preferred size
JPanel midDigits = new JPanel();
midDigits.setPreferredSize(new Dimension(200,60));
//Initialize the bottom digits' JPanel and set its preferred size
JPanel botDigits = new JPanel();
botDigits.setPreferredSize(new Dimension(200, 75));
//Initialize the JButton array
digits = new JButton[11];
//Initialize each of the top Panel's digit buttons, and add it to the top panel
for(int i=1; i<4; i++)
String lab=(new Integer(i)).toString();
digits=new JButton(lab);
topDigits.add(digits);
//Adding the top Digit Panel to the overall digit panel
digPanel.add(topDigits, BorderLayout.CENTER);
//Adding the middle Digit Panel to the overall digit panel
digPanel.add(midDigits, BorderLayout.CENTER);
//Adding the bottom Digit Panel to the overall digit panel
digPanel.add(botDigits, BorderLayout.CENTER);
//Add the overall digit Panel to the Frame's contentpane
contentPane.add(digPanel, BorderLayout.CENTER);
//Method created to add the DigitAction Listeners
addDigitActionListeners();
//Method created to add all of the DigitActionListeners
private void addDigitActionListeners()
for(int i=0; i<10; i++)
digits.addActionListener(new DigitActionListener(i));
digits[10].addActionListener(new DigitActionListener("."));
//DigitActionListener class
public class DigitActionListener implements ActionListener
private String myNum;
public DigitActionListener(int num)
myNum=""+num;
public DigitActionListener(String num)
myNum=num;
public void actionPerformed(ActionEvent e)
if(display.getText().equals("Please enter a valid number")|| clearScreen)
clearScreen=false;
display.setText("");
//OperatorActionListener class
public void OpActionListener implements ActionListener
private int myOpNum;
public OpActionListener(int op)
myOpNum=op;
public void actionPerformed(ActionEvent e)
{ //Checks to see if the user has already enterd a number
if(!firstFilled)
try{
//Parse the number entered
String number=display.getText();
dNum1=Double.parseDouble(number);
//Sets the flag for the firstFilled to true
firstFilled=true
//Sets the op variable so when the "Enter" button is pressed, it will know which operation to perform
op=myOpNum;
//Clears the textbox
display.setText("");
catch(Exception er)
display.setText("Please enter a valid number");
//This is the second number being entered
else{
try{
String number=display.getText();
String result;
dNum2=Double.parseDouble(number);
firstFilled=true;
op=myOpNum;
display.setText("");
catch(Exception er)
display.setText("Please enter a valid number");
private void addOperation()
JPanel opPanel=new JPanel();
opPanel.setPreferredSize(new Dimension(75,200));
JButton clear = new JButton("C");
JButton addition = new JButton("+");
JButton subtraction = new JButton("-");
JButton multiply = new JButton("*");
JButton divide = new JButton("/");
JButton mod = new JButton("%");
JButton enter = new JButton("Enter");
addition.addActionListener(new OpActionListener(ADD));
subtraction.addActionListener(new OpActionListener(SUB));
multiply.addActionListener(new OpActionListener(MUL));
divide.addActionListener(new OpActionListener(DIV));
mod.addActionListener(new OpActionListener(MOD));
clear.addActionListener(new ActionListener()
public void actionPerformed(ActionEvent e)
display.setText("");
firstFilled=false;
enter.addActionListener(new ActionListener()
public void actionPerformed(ActionEvent e)
double result;
String answer="";
String number = display.getText();
dNum2 = Double.parseDouble(number);
dNum1=Double.parseDouble(number);
switch(op)
case ADD:
result = dNum1 + dNum2;
break;
case SUB:
result = dNum1 - dNum2;
break;
case MUL:
result = dNum1 * dNum2;
break;
case DIV:
result = dNum1 / dNum2;
break;
default:
result= -1.0;
break;
if(result==(int)result)
answer=(new Integer((int)result)).toString();
else
answer=(new Double(result)).toString();
display.setText(answer);
clearScreen=true;
firstFilled=false;
dNum1=0;
dNum2=0;
opPanel.add(clear);
opPanel.add(addition);
opPanel.add(subtraction);
opPanel.add(multiply);
opPanel.add(divide);
opPanel.add(mod);
opPanel.add(enter);
contentPane.add(opPanel, "East");
//Creating the frame object
public class CalculatorMain
public void main(String[] args)
CalculatorFrame cf=new CalculatorFrame();
cf.show();
ERRORS THAT I HAVE!!:
javac calculatorframe.javacalculatorframe.java:150: '(' expected
public void OpActionListener implements ActionListener
^
calculatorframe.java:7: class CalculatorFrame is public, should be declared in a file named CalculatorFrame.java
public class CalculatorFrame extends JFrame
^
calculatorframe.java:54: cannot resolve symbol
symbol : method addOperation ()
location: class CalculatorFrame
addOperation();
^
3 errors
>

Here I did this for someone in the 'new to' forum about 2 weeks back. They had some really awful code they say they got from a java book -cannot recall the author, but I do know his work should be burned and the person executed with a mercy killing (I still haven't recovered from the shock of this and I think most of the regular contributors in these forums could write FAR BETTER books than this clown)
Hmm... I do rant sometimes. Erm, you're welcome - this is their rebuild;-import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
public class Calculator extends JFrame implements ActionListener{
   JButton []buttons = new JButton[25];
     private JTextField display= new JTextField("0.0",12);
   String status = "    Status : ";
   JLabel label = new JLabel(status);
     private double sum    = 0.0d;
     private String nums   = "";
     private double arg    = 0.0d;
     private double tot    = 0.0d;
     private boolean start = true,div,mult,add,sub;
     private String memory = "0";
   java.text.DecimalFormat df=new java.text.DecimalFormat("#,##0.0####");
   Font f = new Font("Times New Roman", Font.BOLD,14);
   Color midBlue  = new Color(20, 15, 140);
public Calculator(){
     super();
     setTitle("Java Calculator");
   JPanel mainPan = new JPanel();
   mainPan.setLayout(new BorderLayout() );
   JPanel textPanel = new JPanel();
   textPanel.setBackground(midBlue);
   textPanel.setLayout(new BorderLayout());
   display.setHorizontalAlignment(JTextField.RIGHT);
   label.setForeground(Color.white);
   display.setFont(new Font("",0,14));
   display.setEditable(false);
   display.setBackground(Color.white);
   label.setFont(new Font("Arial",0,12));
   JPanel emptyPan = new JPanel();
   emptyPan.setBackground(midBlue);
   JPanel emptyP1 = new JPanel();
   emptyP1.setBackground(midBlue);
   JPanel emptyP2 = new JPanel();
   emptyP2.setBackground(midBlue);
   textPanel.add("North", label);
   textPanel.add("Center", display);
   textPanel.add("South",emptyPan );
   textPanel.add("East",emptyP1 );
   textPanel.add("West",emptyP2 );
   JPanel butPanel = new JPanel();
   butPanel.setBackground(midBlue);
   butPanel.setLayout(new GridLayout(5, 5, 10, 10));
   String []str = {"","","","CE","C","1","2","3","/","RM","4","5","6",
                  "*","CM","7","8","9","+","M+","0",".","=","-","M-"};
   for(int j=0; j<25; j++) {
      if(j<3) {
         buttons[j] = new JButton(str[j]);
         butPanel.add(buttons[j]);
      else {
         buttons[j] = new JButton(str[j]);
         buttons[j].addActionListener(this);
         buttons[j].setFont(f);
           buttons[j].setBorder(BorderFactory.createRaisedBevelBorder());
         butPanel.add(buttons[j]);
   JPanel emptyPan1 = new JPanel();
   emptyPan1.setBackground(midBlue);
   JPanel emptyPan2 = new JPanel();
   emptyPan2.setBackground(midBlue);
   JPanel emptyPan3 = new JPanel();
   emptyPan3.setBackground(midBlue);
   mainPan.add("North", textPanel);
   mainPan.add("Center", butPanel);
   mainPan.add("South", emptyPan1);
   mainPan.add("East", emptyPan2);
   mainPan.add("West", emptyPan3);
   getContentPane().add(mainPan);
public void actionPerformed(ActionEvent e){
   String s = e.getActionCommand();
      if ((s.equals("1"))||(s.equals("2"))||(s.equals("3"))||(s.equals("4"))
        ||(s.equals("5"))||(s.equals("6"))||(s.equals("7"))||(s.equals("8"))
        ||(s.equals("9"))||(s.equals("0"))||(s.equals("."))){
           nums += s;
           display.setText(nums);
      if (s.equals("/")){
         arg=Double.parseDouble(display.getText());
         nums="";
         div=true;
      if (s.equals("*")){
         arg=Double.parseDouble(display.getText());
         nums="";
         mult=true;
      if (s.equals("-")){
         arg=Double.parseDouble(display.getText());
         nums="";
         sub=true;
      if (s.equals("+")){
         arg=Double.parseDouble(display.getText());
         nums="";
         add=true;
      if (s.equals("=")){
         tot=Double.parseDouble(display.getText());
         if(div)tot=arg/tot;
         if(mult)tot=arg*tot;
         if(add)tot=arg+tot;
         if(sub)tot=arg-tot;
         display.setText(df.format(tot));
         div=mult=sub=add=false;
public static void main(String[] args){
    Calculator frame = new Calculator();
    frame.setVisible(true);
    frame.setDefaultCloseOperation( EXIT_ON_CLOSE );
      Image onFrame = Toolkit.getDefaultToolkit().getImage("flag.gif") ;
    frame.setIconImage(onFrame);
    frame.setLocation(300, 240);
    frame.setResizable(false);
    frame.pack();
}

Similar Messages

  • Please Help/ GUI Calculator

    I'm trying to create a GUI Calculator but cannot get my program to compile. Please could someone assistm, thanks.
    import java.io.*;
    import java.util.*;
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    public class CalculatorFrame extends JFrame
         private Container contentPane;
         //The componenets used in the calculator
         private JTextField display;
         private JButton addition;
         private JButton subtract;
         private JButton multiply;
         private JButton divide;
         private JButton mod;
         private JButton enter;
         private JButton [] digits;
         //End of components
         //Integer representations for the arithmetic operations needed
         private final static int ADD = 1;
         private final static int SUB = 2;
         private final static int MUL = 3;
         private final static int DIV = 4;
         private final static int MOD = 5;
         //ENd of arithmethic operations
         //Integer holding the operator that the user requested
         private int op;
         //Boolean variable to help perform the calculations
         private boolean firstFilled;
         private boolean clearScreen;
         //Constructor for the class
         public CalculatorFrame()
         contentPane=new Container();
         this.setSize(400,300); //sets the size of the frame
         this.setTitle("MIS 222 Calculator"); //sets the title of the frame
         //allows the "X" box in the upper right hand corner to close the entire application
         this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
         contentPane=this.getContentPane(); //gets the content pane
         //Methods
         addDisplay();
         addDigits();
         addDigitActionListeners();
         addOperation();
    private void addDisplay()
         JLabel displayLab = new JLabel("Answer");
         JPanel north = new JPanel();
         north.add(displayLab);
         contentPane.add(north, "North");
    //diplay was already declared above the constructor
         display = new JTextField(25);
    //adding the components to the panel
         north.add(displayLab);
         north.add(display);
    //adding the panel to frame's content pane
         contentPane.add(north, "North");
    //Declaring the global digits array
    private void addDigits()
         //Add 1 large panel to hold the 3 inner panels
         JPanel digPanel = new JPanel();
         //Set the panel's preferred size so that it will keep everything in line
         digPanel.setPreferredSize(new Dimension(200, 275));
         //Initialize the top 3 digits' JPanel and set its preferrd size
         JPanel topDigits = new JPanel();
         topDigits.setPreferredSize(new Dimension(200,60));
         //Initialize the middle 2 digits' JPanel and set its preferred size
         JPanel midDigits = new JPanel();
         midDigits.setPreferredSize(new Dimension(200,60));
         //Initialize the bottom digits' JPanel and set its preferred size
         JPanel botDigits = new JPanel();
         botDigits.setPreferredSize(new Dimension(200, 75));
         //Initialize the JButton array
         digits = new JButton[11];
         //Initialize each of the top Panel's digit buttons, and add it to the top panel
         for(int i=1; i<4; i++)
              String lab=(new Integer(i)).toString();
              digits=new JButton(lab);
              topDigits.add(digits[i]);
              //Adding the top Digit Panel to the overall digit panel
              digPanel.add(topDigits, BorderLayout.CENTER);
              //Adding the middle Digit Panel to the overall digit panel
              digPanel.add(midDigits, BorderLayout.CENTER);
              //Adding the bottom Digit Panel to the overall digit panel
              digPanel.add(botDigits, BorderLayout.CENTER);
              //Add the overall digit Panel to the Frame's contentpane
              contentPane.add(digPanel, BorderLayout.CENTER);
              //Method created to add the DigitAction Listeners
              addDigitActionListeners();
    //Method created to add all of the DigitActionListeners
    private void addDigitActionListeners()
              for(int i=0; i<10; i++)
                   digits[i].addActionListener(new DigitActionListener(i));
              digits[10].addActionListener(new DigitActionListener("."));
    //DigitActionListener class
    public class DigitActionListener implements ActionListener
         private String myNum;
         public DigitActionListener(int num)
              myNum=""+num;
         public DigitActionListener(String num)
              myNum=num;
         public void actionPerformed(ActionEvent e)
              if(display.getText().equals("Please enter a valid number")|| clearScreen)
                   clearScreen=false;
                   display.setText("");
    //OperatorActionListener class
    public void OpActionListener implements ActionListener
         private int myOpNum;
         public OpActionListener(int op)
              myOpNum=op;
         public void actionPerformed(ActionEvent e)
         {  //Checks to see if the user has already enterd a number
              if(!firstFilled)
              try{
                   //Parse the number entered
                   String number=display.getText();
                   dNum1=Double.parseDouble(number);
                   //Sets the flag for the firstFilled to true
                   firstFilled=true
                   //Sets the op variable so when the "Enter" button is pressed, it will know which operation to perform
                   op=myOpNum;
                   //Clears the textbox
                   display.setText("");
                   catch(Exception er)
                        display.setText("Please enter a valid number");
         //This is the second number being entered
              else{
                   try{
                        String number=display.getText();
                        String result;
                        dNum2=Double.parseDouble(number);
                        firstFilled=true;
                        op=myOpNum;
                        display.setText("");
                   catch(Exception er)
                        display.setText("Please enter a valid number");
    private void addOperation()
         JPanel opPanel=new JPanel();
         opPanel.setPreferredSize(new Dimension(75,200));
         JButton clear = new JButton("C");
         JButton addition = new JButton("+");
         JButton subtraction = new JButton("-");
         JButton multiply = new JButton("*");
         JButton divide = new JButton("/");
         JButton mod = new JButton("%");
         JButton enter = new JButton("Enter");
         addition.addActionListener(new OpActionListener(ADD));
         subtraction.addActionListener(new OpActionListener(SUB));
         multiply.addActionListener(new OpActionListener(MUL));
         divide.addActionListener(new OpActionListener(DIV));
         mod.addActionListener(new OpActionListener(MOD));
         clear.addActionListener(new ActionListener()
              public void actionPerformed(ActionEvent e)
                   display.setText("");
                   firstFilled=false;
         enter.addActionListener(new ActionListener()
              public void actionPerformed(ActionEvent e)
                   double result;
                   String answer="";
                   String number = display.getText();
                   dNum2 = Double.parseDouble(number);
                   dNum1=Double.parseDouble(number);
                   switch(op)
                        case ADD:
                             result = dNum1 + dNum2;
                             break;
                        case SUB:
                             result = dNum1 - dNum2;
                             break;
                        case MUL:
                             result = dNum1 * dNum2;
                             break;
                        case DIV:
                             result = dNum1 / dNum2;
                             break;
                        default:
                             result= -1.0;
                             break;
                        if(result==(int)result)
                             answer=(new Integer((int)result)).toString();
                        else
                             answer=(new Double(result)).toString();
                        display.setText(answer);
                        clearScreen=true;
                        firstFilled=false;
                        dNum1=0;
                        dNum2=0;
              opPanel.add(clear);
              opPanel.add(addition);
              opPanel.add(subtraction);
              opPanel.add(multiply);
              opPanel.add(divide);
              opPanel.add(mod);
              opPanel.add(enter);
              contentPane.add(opPanel, "East");
         //Creating the frame object
         public class CalculatorMain
              public void main(String[] args)
                   CalculatorFrame cf=new CalculatorFrame();
                   cf.show();
    ERRORS THAT I HAVE!!:
    javac calculatorframe.javacalculatorframe.java:150: '(' expected
    public void OpActionListener implements ActionListener
    ^
    calculatorframe.java:7: class CalculatorFrame is public, should be declared in a file named CalculatorFrame.java
    public class CalculatorFrame extends JFrame
    ^
    calculatorframe.java:54: cannot resolve symbol
    symbol : method addOperation ()
    location: class CalculatorFrame
    addOperation();
    ^
    3 errors
    >

    Hi, actually it's all written there:
    >
    ERRORS THAT I HAVE!!:
    javac calculatorframe.javacalculatorframe.java:150: '(' expected
    public void OpActionListener implements
    ActionListenerpublic void ... is part of a possible method signature. That's probably why the compiler expects '(' as this is need for a method.
    To define a class use:
    public class ... (or better: private class ..., if the class is not used outside of this file.
    ^
    calculatorframe.java:7: class CalculatorFrame is
    public, should be declared in a file named
    CalculatorFrame.java
    public class CalculatorFrame extends JFrame
    ^As it says, you defined a class CalculatorFrame in a file calculatorframe.java. But the file name should be the same as the class name (case sensitive). Java classes should start with capital letters, so rename the file to:
    CalculatorFrame.java
    calculatorframe.java:54: cannot resolve symbol
    symbol : method addOperation ()
    location: class CalculatorFrame
    addOperation();
    ^
    3 errors
    >You didn't declare the method 'addOperation' (-> cannot resolve symbol; which simbol: method addOperation (); where: location: class CalculatorFrame; you see it's all there)
    Note there is a method called 'addOperation' in the class OpActionListener, but not in CalculatorFrame.
    Note I didn't read the code, just the error messages. I hope this helps.
    -Puce

  • Help please- GUI calculator

    I am trying to create a GUI calculator which:
    -must use the JOptionPane class to create dialog boxes for user input and
    output.
    -If the user attempts to divide by 0, you must print a message to that effect (e.g.,
    "division by 0 not allowed").
    -If the user enters an invalid operator, you must print a message to that effect
    (e.g., "operation not supported").
    My Program will not work, and any help would be greatly appreciated!
    import javax.swing.JOptionPane;
    public class GUI {
         String numberString =
              JOptionPane.showInputDialog("Welcome to my GUI Calculator!\n The following operations are supported:\n +(addition), -(subtraction), *(multiplication)\n /(division),and ^(exponent)\n\n Enter your calculation separated by spaces and press OK.\n Example:2.5 + 3");
         int firstSpace =
         numberString.indexOf(" ");
         double answer;
         double
         operand1 = Double.parseDouble(numberString.substring(0,firstSpace));
         double
         operand2 = Double.parseDouble(numberString.substring(firstSpace+3,numberString.length()));
         char
         operator = numberString.charAt(firstSpace+1);
         while (operator == "+")
              answer = operand1 + operand2;
         while (operator == "-")
              answer = operand1 - operand2;
         while (operator == "*")
              answer = operand1 * operand2;
         while (operator == "/")
         { if (operand2 == 0)
              JOptionPane.showInputDialog("Division by 0 not allowed!");
              else
              answer = operand1 / operand2;
         while (operator == "^")
              answer = Math.pow(operand1, operand2);
    while (operator != "+, -, *, /, ^")
         JOptionPane.showInputDialog("Operation not supported.");
    JOptionPane.showMessageDialog("numberString = answer");
    System.exit(0);
    }

    When you post code, please wrap it in [code] [/code] tags so it's easy to read.
    You're confusing strings with characters. You read the operator as a character. But when you check it, you compare it with Strings (you can tell they're Strings because you're using double quotes). You should be using single quotes there.
    Your code makes a lot of assumptions about the format of the data it's given, for example the number of spaces and where they'll appear.
    And this part:while (operator != "+, -, *, /, ^") There's absolutely no reason why that would work. Where did you get the idea that was a thing to do? If you want to see if the operator is in a list of characters, there are a variety of things you can do, but probably the simplest is just to have five if/else statements. You're going to need those anyway when you do the math operation; when you get to the last one, just put an else statement saying that you don't recognize the operator.

  • GUI Calculator (Swing, BorderLayout, etc.)

    I am a bit of a crossroads and am needing some advice. I am trying to create a Calculator in a Window (GUI) that looks similar to a keypad. I have three files that I am working on but cannot get any of them to compile without errors. I am confused as to what I have left out and/or where I have taken a wrong turn. I will post them below and would greatly appreciate any insight and/or direction as to how to make this work! Also, I have heard from a "birdie" that there may be some problems that occur if the files are compiled out of order....does this make sense to anyone? Thank you in
    advance for any help--Christle
    Constants.java file
    //Christle Chumney
    import java.awt.*;
    public interface Constants
      Color FUNCTION_COLOR = Color.red;
      Color OPERATOR_COLOR = Color.blue;
      Color NUMBER_COLOR = Color.black;
    }calculator.java file
    //Christle Chumney
    import java.awt.*;
    public class Calculator  {
      public static void main(String[] args){
         theApp = new Calculator();
         theApp.init();
      public void init() {
        aWindow = new CalculatorFrame("My Calculator");
        aWindow.setBounds(10, 10, 250, 250);
        aWindow.setVisible(true); }
      private static CalculatorFrame aWindow;
      private static Calculator theApp;
    }calculatorFrame.java file
    //Christle Chumney
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.border.*;
    import java.util.*;
    public class CalculatorFrame extends JFrame implements Constants //, ActionListener
      private Calculator theApp;
      JPanel top, bottom;
      JTextField display;
      JButton button;
      // Constructor
      public CalculatorFrame(String title)
        setTitle(title);  // Set the window title
        this.theApp = theApp;
        JMenuBar swingMenuBar = new JMenuBar();
        JMenu swingMenu = new JMenu("swingMenu");
        JMenuItem swingMenuItem1, swingMenuItem2, swingMenuItem3;
         swingMenuBar.add(swingMenu);
         setJMenuBar(swingMenuBar);
        JMenu applicationMenu = new JMenu("Function");    // Create Application menu
        applicationMenu.setMnemonic('A');                    // Create shortcut
        // Construct the application pull down menu
        exitItem = applicationMenu.add("Exit");                // Add exit item
        exitItem.setAccelerator(KeyStroke.getKeyStroke('X',Event.CTRL_MASK ));
        applicationMenu.add(exitItem);
        menuBar.add(applicationMenu);                        // Add the file menu   
        makeButtons();
      public void makeButtons() {
        BorderLayout border = new BorderLayout();
        Container content = getContentPane();
        content.setLayout(border);
        top = new JPanel(new BorderLayout());
        display = new JTextField("");
        display.setEditable(false);
        display.setBackground(Color.white);
        display.setHorizontalAlignment(display.RIGHT);
        top.add(display);
        bottom = new JPanel();
        GridLayout grid = new GridLayout(5,4,5,5);
        bottom.setLayout(grid);
        bottom.add(button = new JButton("C"));
        button.setForeground(FUNCTION_COLOR);
        bottom.add(button = new JButton("<=="));
        button.setForeground(FUNCTION_COLOR);
        bottom.add(button = new JButton("%"));
        button.setForeground(OPERATOR_COLOR);
        bottom.add(button = new JButton("/"));
        button.setForeground(OPERATOR_COLOR);
        bottom.add(button = new JButton("7"));
        bottom.add(button = new JButton("8"));
        bottom.add(button = new JButton("9"));
        bottom.add(button = new JButton("*"));
        button.setForeground(OPERATOR_COLOR);
        bottom.add(button = new JButton("4"));
        bottom.add(button = new JButton("5"));
        bottom.add(button = new JButton("6"));
        bottom.add(button = new JButton("-"));
        button.setForeground(OPERATOR_COLOR);
        bottom.add(button = new JButton("1"));
        bottom.add(button = new JButton("2"));
        bottom.add(button = new JButton("3"));
        bottom.add(button = new JButton("+"));
        button.setForeground(OPERATOR_COLOR);
        bottom.add(button = new JButton("0"));
        bottom.add(button = new JButton("+/-"));
        bottom.add(button = new JButton("."));
        bottom.add(button = new JButton("="));
        button.setForeground(OPERATOR_COLOR);
         Container content = aWindow.getContentPane();
         content.setLayout(new BorderLayout());
         content.add(top, BorderLayout, NORTH);
         content.add(bottom, BorderLayout, CENTER);
      private JMenuBar menuBar = new JMenuBar();      // Window menu bar
      private JMenuItem exitItem;                       // application menu item 
    }Thanks in advance (again)-
    Christle

    HERE R U .JAVA FILES AND THEY WORK FINE NOW NO ERRORS NOTHING JUST THAT U HAVE TO CODE THE EVENTS OF UR APPLICATION
    ANYOTHER HELP U NEED UR MOST WELCOME
    VIJAY
    // CALCULATORFRAME.JAVA
    //Christle Chumney
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.border.*;
    import java.util.*;
    public class CalculatorFrame extends JFrame implements Constants //,ActionListener
         private Calculator theApp;
         JPanel top, bottom;
         JTextField display;
         JButton button;
    // Constructor
         public CalculatorFrame(String title)
              setTitle(title);
    // Set the window title
              this.theApp = theApp;
              JMenuBar swingMenuBar = new JMenuBar();
              JMenu swingMenu = new JMenu("swingMenu");
              JMenuItem swingMenuItem1, swingMenuItem2, swingMenuItem3;     
              swingMenuBar.add(swingMenu);     
              setJMenuBar(swingMenuBar);
              JMenu applicationMenu = new JMenu("Function");
    // Create Application menu
              applicationMenu.setMnemonic('A');
    // Create shortcut
    // Construct the application pull down menu
              exitItem = applicationMenu.add("Exit");
    // Add exit item           exitItem.setAccelerator(KeyStroke.getKeyStroke('X',Event.CTRL_MASK ));           applicationMenu.add(exitItem);
              menuBar.add(applicationMenu);
    // Add the file menu
              makeButtons();
    public void makeButtons()
         BorderLayout border = new BorderLayout();
         Container content = getContentPane();
         content.setLayout(border);
         top = new JPanel(new BorderLayout());
         display = new JTextField("");
         display.setEditable(false);
         display.setBackground(Color.white);
         display.setHorizontalAlignment(display.RIGHT);
         top.add(display);
         bottom = new JPanel();
         GridLayout grid = new GridLayout(5,4,5,5);
         bottom.setLayout(grid);
         bottom.add(button = new JButton("C"));
         button.setForeground(FUNCTION_COLOR);
    bottom.add(button = new JButton("<=="));
         button.setForeground(FUNCTION_COLOR);
         bottom.add(button = new JButton("%"));
         button.setForeground(OPERATOR_COLOR);
         bottom.add(button = new JButton("/"));
         button.setForeground(OPERATOR_COLOR);
         bottom.add(button = new JButton("7"));
         bottom.add(button = new JButton("8"));
         bottom.add(button = new JButton("9"));
         bottom.add(button = new JButton("*"));
         button.setForeground(OPERATOR_COLOR);
         bottom.add(button = new JButton("4"));
         bottom.add(button = new JButton("5"));
         bottom.add(button = new JButton("6"));
         bottom.add(button = new JButton("-"));
         button.setForeground(OPERATOR_COLOR);
         bottom.add(button = new JButton("1"));
         bottom.add(button = new JButton("2"));
         bottom.add(button = new JButton("3"));
         bottom.add(button = new JButton("+"));
         button.setForeground(OPERATOR_COLOR);
         bottom.add(button = new JButton("0"));
         bottom.add(button = new JButton("+/-"));
         bottom.add(button = new JButton("."));
         bottom.add(button = new JButton("="));
         button.setForeground(OPERATOR_COLOR);     
         Container content1 = this.getContentPane();     
         content.setLayout(new BorderLayout());
         content1.add(top, BorderLayout.NORTH);
         content1.add(bottom, BorderLayout.CENTER);
         private JMenuBar menuBar = new JMenuBar();
    // Window menu bar
         private JMenuItem exitItem;
    // application menu item
    // CALCULATOR.JAVA
    import java.awt.*;
    public class Calculator
    public static void main(String[] args)
    {     theApp = new Calculator();
         theApp.init();
    public void init()
    aWindow = new CalculatorFrame("My Calculator");
    aWindow.setBounds(10, 10, 250, 250);
    aWindow.setVisible(true);
    private static CalculatorFrame aWindow;
    private static Calculator theApp;
    // CONSTANTS.JAVA
    import java.awt.*;
    public interface Constants
    Color FUNCTION_COLOR = Color.red;
    Color OPERATOR_COLOR = Color.blue;
    Color NUMBER_COLOR = Color.black;

  • HC - A scientific, graphing, supp complex nums CLI and GUI calculator

    I uploaded all three packages to AUR! Please use the PKGBUILDs there if you want to install this now. Thanks a lot goran'agar and foutrelis for help with the PKGBUILDs.
    AUR links:
    mapm : http://aur.archlinux.org/packages.php?ID=32319
    hc : http://aur.archlinux.org/packages.php?ID=32321
    hcg : http://aur.archlinux.org/packages.php?ID=32320
    UPDATE (28.2.2010) : I now also finally have a github account where you can find the newest version of hc (cli only) which obviously has all the newest things I implemented but on the other hand it may be unstable. Anyway, here's the link : http://github.com/houbysoft/hc
    Hello ArchLinux users,
    some time ago, I was a little unsatisfied with existing calculators (either it was too memory/CPU-consuming (it had to work well, among others, on a 128MB RAM computer), or it lacked the functions I needed (f.ex. nCr and nPr)), and so I decided to write my own command-line (now there also is a GUI version) calculator.
    Here is a little description:
    The goal of this program is to provide an open source calculator with a
    simple and easy-to-use interface, similar to a command prompt, but a lot of
    options and a multitude of functions.
    You can also type "help" in the command prompt if you need any help - or
    contact me here.
    There are two major versions of HC -- a CLI (command line interface) and a
    GUI (graphical user interface).
    To get you an idea, have some screenshots:
    CLI version
    GUI version
    I thought some of you might like it, so I posted it here. It is of course open source (GPL v3) and cross-platform (precompiled for Linux and Windows).
    The calculator's homepage is
    http://houbysoft.com/hc/
    If you're interested, you'll find a lot more details there.
    Please post some feedback/criticism etc.; also please report any bugs - I started this project ~2 months ago so it is not yet completely stable and complete.
    Thanks for reading, give it a try!
    Last edited by y27 (2010-03-01 01:24:13)

    goran'agar wrote:I'm not able to create any PKGBUILD for the application itself as the website executes a php script before allowing the download.
    Thanks a lot, I'll test it out soon.
    If you'd help me with the PKGBUILD for my app itself, the full links are:
    http://houbysoft.com/download/hc-VERSION-TYPE.tar.gz
    where VERSION is the version number, so for example 0.4.2, and TYPE is either linux or src.
    I'm not sure which format of URLs is needed so please ask me if you need something else.
    Also, for windows versions, the urls are:
    http://houbysoft.com/download/hc-VERSION-win.[b]zip[/b]
    (in case you care).
    tomd123 wrote:Feature requests: variable assignment and function declaration.
    BTW, have you considered using the python interpretor for your calculations? If the functions you need aren't already in it, you can easily add them.
    Functions and variables:
    I'll put it on my roadmap
    For the python interpreter : yes, I did, but dismissed it because:
    - it's not very convenient - you have to retype stuff to floats if you don't want only integer results
    - it's slow (again, this had to work and take a very small amount of CPU and memory on a 333MHz and 128 MB RAM system), and in algorithms where speed is crucial this would be even more of a concern
    - I know about psyco to speed it up, but AFAIK it doesn't work on 64bit processors
    - I wanted it to be small and minimalistic, installing a python distribution imo isn't
    - I like programming, writing a calculator is fun

  • Help on GUI calculator

    I'm making a calculator on netbeans and so far i have been able to get the interface and an the function of the number buttons. Also I got the plus button to work but it does not work after using it once. I have tried, but im stuck and can't firgure out what to do next plz help. This is the code i have:
    * Calulator.java
    * Created on April 3, 2008, 11:30 AM
    package me;
    * @author period4
    public class Calulator extends javax.swing.JFrame {
    /** Creates new form Calulator */
    public Calulator() {
    initComponents();
    /** This method is called from within the constructor to
    * initialize the form.
    * WARNING: Do NOT modify this code. The content of this method is
    * always regenerated by the Form Editor.
    // <editor-fold defaultstate="collapsed" desc=" Generated Code ">//GEN-BEGIN:initComponents
    private void initComponents() {
    jButton17 = new javax.swing.JButton();
    Input = new javax.swing.JTextField();
    Button1 = new javax.swing.JButton();
    Button4 = new javax.swing.JButton();
    Button7 = new javax.swing.JButton();
    Button2 = new javax.swing.JButton();
    Button5 = new javax.swing.JButton();
    Button8 = new javax.swing.JButton();
    Button3 = new javax.swing.JButton();
    Button6 = new javax.swing.JButton();
    Button9 = new javax.swing.JButton();
    Button0 = new javax.swing.JButton();
    ButtonPlus = new javax.swing.JButton();
    ButtonMinus = new javax.swing.JButton();
    ButtonMultiply = new javax.swing.JButton();
    ButtonDecimal = new javax.swing.JButton();
    ButtonPositiveNegative = new javax.swing.JButton();
    ButtonDivide = new javax.swing.JButton();
    ButtonEquals = new javax.swing.JButton();
    jButton17.setText("jButton17");
    setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
    setTitle("Calculator");
    Button1.setText("1");
    Button1.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button1ActionPerformed(evt);
    Button4.setText("4");
    Button4.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button4ActionPerformed(evt);
    Button7.setText("7");
    Button7.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button7ActionPerformed(evt);
    Button2.setText("2");
    Button2.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button2ActionPerformed(evt);
    Button5.setText("5");
    Button5.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button5ActionPerformed(evt);
    Button8.setText("8");
    Button8.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button8ActionPerformed(evt);
    Button3.setText("3");
    Button3.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button3ActionPerformed(evt);
    Button6.setText("6");
    Button6.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button6ActionPerformed(evt);
    Button9.setText("9");
    Button9.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button9ActionPerformed(evt);
    Button0.setText("0");
    Button0.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    Button0ActionPerformed(evt);
    ButtonPlus.setText("+");
    ButtonPlus.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    ButtonPlusActionPerformed(evt);
    ButtonMinus.setText("-");
    ButtonMultiply.setText("*");
    ButtonDecimal.setText(".");
    ButtonDecimal.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    ButtonDecimalActionPerformed(evt);
    ButtonPositiveNegative.setText("+/-");
    ButtonDivide.setText("/");
    ButtonEquals.setText("=");
    ButtonEquals.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    ButtonEqualsActionPerformed(evt);
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(
    layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
    .addGroup(layout.createSequentialGroup()
    .addContainerGap()
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
    .addComponent(Input, javax.swing.GroupLayout.DEFAULT_SIZE, 227, Short.MAX_VALUE)
    .addGroup(layout.createSequentialGroup()
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
    .addGroup(layout.createSequentialGroup()
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
    .addComponent(Button7, javax.swing.GroupLayout.Alignment.LEADING, 0, 0, Short.MAX_VALUE)
    .addComponent(Button4, javax.swing.GroupLayout.Alignment.LEADING, 0, 0, Short.MAX_VALUE)
    .addComponent(Button1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
    .addComponent(Button2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
    .addComponent(Button5, 0, 0, Short.MAX_VALUE)
    .addComponent(Button8, 0, 0, Short.MAX_VALUE))
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
    .addGroup(layout.createSequentialGroup()
    .addComponent(Button3)
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addComponent(ButtonPlus))
    .addGroup(layout.createSequentialGroup()
    .addComponent(Button6)
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addComponent(ButtonMinus))
    .addGroup(layout.createSequentialGroup()
    .addComponent(Button9)
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addComponent(ButtonMultiply))))
    .addGroup(layout.createSequentialGroup()
    .addComponent(ButtonDecimal)
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addComponent(Button0)
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addComponent(ButtonPositiveNegative)
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addComponent(ButtonDivide)))
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addComponent(ButtonEquals)))
    .addContainerGap())
    layout.setVerticalGroup(
    layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
    .addGroup(layout.createSequentialGroup()
    .addGap(22, 22, 22)
    .addComponent(Input, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
    .addGroup(layout.createSequentialGroup()
    .addGap(15, 15, 15)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
    .addComponent(Button1)
    .addComponent(Button2)
    .addComponent(Button3)
    .addComponent(ButtonPlus))
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
    .addComponent(Button4)
    .addComponent(Button5)
    .addComponent(Button6)
    .addComponent(ButtonMinus))
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
    .addComponent(Button7)
    .addComponent(Button8)
    .addComponent(Button9)
    .addComponent(ButtonMultiply))
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
    .addComponent(ButtonDecimal)
    .addComponent(Button0)
    .addComponent(ButtonPositiveNegative)
    .addComponent(ButtonDivide)))
    .addGroup(layout.createSequentialGroup()
    .addGap(17, 17, 17)
    .addComponent(ButtonEquals, javax.swing.GroupLayout.PREFERRED_SIZE, 110, javax.swing.GroupLayout.PREFERRED_SIZE)))
    .addContainerGap(44, Short.MAX_VALUE))
    pack();
    }// </editor-fold>//GEN-END:initComponents
    private void ButtonEqualsActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_ButtonEqualsActionPerformed
    if(operator.equals("+"))
    solution = Double.parseDouble(integer1) + Double.parseDouble(integer2);
    Input.setText(Double.toString(solution));
    operator = null;
    integer1 = "";
    integer2 = "";
    //Input.setText(Double.toString(solution));
    solution = 0;
    // TODO add your handling code here:
    }//GEN-LAST:event_ButtonEqualsActionPerformed
    private void ButtonPlusActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_ButtonPlusActionPerformed
    operator = "+";
    // TODO add your handling code here:
    }//GEN-LAST:event_ButtonPlusActionPerformed
    private void ButtonDecimalActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_ButtonDecimalActionPerformed
    Input.setText(".");// TODO add your handling code here:
    }//GEN-LAST:event_ButtonDecimalActionPerformed
    private void Button0ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button0ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("0");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("0");
    Input.setText(integer2);
    // TODO add your handling code here:
    }//GEN-LAST:event_Button0ActionPerformed
    private void Button9ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button9ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("9");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("9");
    Input.setText(integer2);
    // TODO add your handling code here:
    }//GEN-LAST:event_Button9ActionPerformed
    private void Button6ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button6ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("6");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("6");
    Input.setText(integer2);
    // TODO add your handling code here:
    }//GEN-LAST:event_Button6ActionPerformed
    private void Button3ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button3ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("3");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("3");
    Input.setText(integer2);
    // TODO add your handling code here:
    }//GEN-LAST:event_Button3ActionPerformed
    private void Button8ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button8ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("8");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("8");
    Input.setText(integer2);
    // TODO add your handling code here:
    }//GEN-LAST:event_Button8ActionPerformed
    private void Button5ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button5ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("5");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("5");
    Input.setText(integer2);
    // TODO and your handling code here:
    }//GEN-LAST:event_Button5ActionPerformed
    private void Button7ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button7ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("7");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("7");
    Input.setText(integer2);
    // TODO add your handling code here:
    }//GEN-LAST:event_Button7ActionPerformed
    private void Button4ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button4ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("4");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("4");
    Input.setText(integer2);
    // TODO add your handling code here:
    }//GEN-LAST:event_Button4ActionPerformed
    private void Button1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button1ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("1");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("1");
    Input.setText(integer2);
    // TODO add your handling code here:
    }//GEN-LAST:event_Button1ActionPerformed
    private void Button2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_Button2ActionPerformed
    if(operator == null)
    integer1 = integer1.concat("2");
    Input.setText(integer1);
    else
    integer2 = integer2.concat("2");
    Input.setText(integer2);
    // TODO add your handling code here:
    }//GEN-LAST:event_Button2ActionPerformed
    * @param args the command line arguments
    double solution;
    String integer1 = "";
    String integer2 = "";
    String operator;
    public static void main(String args[])
    java.awt.EventQueue.invokeLater(new Runnable()
    public void run()
    new Calulator().setVisible(true);
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton Button0;
    private javax.swing.JButton Button1;
    private javax.swing.JButton Button2;
    private javax.swing.JButton Button3;
    private javax.swing.JButton Button4;
    private javax.swing.JButton Button5;
    private javax.swing.JButton Button6;
    private javax.swing.JButton Button7;
    private javax.swing.JButton Button8;
    private javax.swing.JButton Button9;
    private javax.swing.JButton ButtonDecimal;
    private javax.swing.JButton ButtonDivide;
    private javax.swing.JButton ButtonEquals;
    private javax.swing.JButton ButtonMinus;
    private javax.swing.JButton ButtonMultiply;
    private javax.swing.JButton ButtonPlus;
    private javax.swing.JButton ButtonPositiveNegative;
    private javax.swing.JTextField Input;
    private javax.swing.JButton jButton17;
    // End of variables declaration//GEN-END:variables
    }

    Yeah. Seriously. I don't think anybody wants to wade through a whole bunch of IDE generated crap that you didn't bother to format with code tags.
    I know I don't.
    So maybe post some formatted relevent code (10 lines or less).

  • Simple calculator to use log, successor, predecessor ?

    Hello. I have this simple calculator program, and I am having trouble with the log, successor (if 8 entered returns 9), predecessor (if 8 entered returns 7). The log gets this error:
    Calculator.java:113: log(double) in java.lang.Math cannot be applied to (int,int)
                   result = (int)Math.log(result, stringToInteger(ioField.getText()));
    I did the same thing with power, and it seems to work so I'm a little confused about that.
    If anyone can help me out it would be greatly appreciated, and thanks in advance!
    Here's the code (commented out code is what I need help with):
    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.*;
    public class Calculator extends JFrame implements ActionListener
         public static final int WIDTH = 400;
         public static final int HEIGHT = 200;
         public static final int NUMBER_OF_DIGITS = 30;
         private JTextField ioField;
         private int result = 0;
         public Calculator()
              setSize(WIDTH, HEIGHT);
              setTitle("GUI Calculator");
              setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              setLayout(new BorderLayout());
              JPanel textPanel = new JPanel();
              textPanel.setLayout(new FlowLayout());
              ioField = new JTextField("Enter numbers here.", NUMBER_OF_DIGITS);
              ioField.setBackground(Color.WHITE);
              textPanel.add(ioField);
              add(textPanel, BorderLayout.NORTH);
              JPanel buttonPanel = new JPanel();
              buttonPanel.setBackground(Color.BLUE);
              buttonPanel.setLayout(new GridLayout(5, 2));
              JButton addButton = new JButton("+");
              addButton.addActionListener(this);
              buttonPanel.add(addButton);
              JButton subButton = new JButton("-");
              subButton.addActionListener(this);
              buttonPanel.add(subButton);
              JButton multButton = new JButton("*");
              multButton.addActionListener(this);
              buttonPanel.add(multButton);
              JButton divButton = new JButton("/");
              divButton.addActionListener(this);
              buttonPanel.add(divButton);
              JButton expButton = new JButton("^");
              expButton.addActionListener(this);
              buttonPanel.add(expButton);
              JButton logButton = new JButton("v");
              logButton.addActionListener(this);
              buttonPanel.add(logButton);
              JButton sucButton = new JButton("s");
              sucButton.addActionListener(this);
              buttonPanel.add(sucButton);
              JButton preButton = new JButton("p");
              preButton.addActionListener(this);
              buttonPanel.add(preButton);
              JButton clearButton = new JButton("C");
              clearButton.addActionListener(this);
              buttonPanel.add(clearButton);
              add(buttonPanel, BorderLayout.CENTER);
         public void actionPerformed(ActionEvent e)
              try
                   assumingCorrectNumberFormats(e);
              catch(NumberFormatException e2)
                   ioField.setText("Error - Reenter number.");
         public void assumingCorrectNumberFormats(ActionEvent e)
              String actionCommand = e.getActionCommand();
              if(actionCommand.equals("+"))
                   result = result + stringToInteger(ioField.getText());
                   ioField.setText(Integer.toString(result));
              else if(actionCommand.equals("-"))
                   result = result - stringToInteger(ioField.getText());
                   ioField.setText(Integer.toString(result));
              else if(actionCommand.equals("*"))
                   result = result * stringToInteger(ioField.getText());
                   ioField.setText(Integer.toString(result));
              else if(actionCommand.equals("/"))
                   result = result / stringToInteger(ioField.getText());
                   ioField.setText(Integer.toString(result));
              else if(actionCommand.equals("^"))
                   result = (int)Math.pow(result, stringToInteger(ioField.getText()));
                   ioField.setText(Integer.toString(result));
    /*          else if(actionCommand.equals("v"))
                   result = (int)Math.log(result, stringToInteger(ioField.getText()));
                   ioField.setText(Integer.toString(result));
              else if(actionCommand.equals("s"))
                   result = result + 1;
              else if(actionCommand.equals("p"))
                   result = result - 1;
    */          else if(actionCommand.equals("C"))
                   result = 0;
                   ioField.setText("0");
              else
                   ioField.setText("Unexpected error.");
         public static int stringToInteger(String stringObject)
              return Integer.parseInt(stringObject.trim());
         public static void main(String[] args)
              Calculator gui = new Calculator();
              gui.setVisible(true);
    }

    A 'double' is not the same as an 'int' and they can't fit the one value-type into the memory of the other.
    Although this is a logical math problem, simple for us, we have better memory than a computer.
    An integer maps a certain amount of memory to fix its maximum value, when you cast, you must cast into a type that is the same or smaller in terms of memory byte size.
    Just like you can't cast some objects as others, you can't cast a double as an int.
    The error is telling you that the result of a method call is incompatiable with the argument of another method call.
    The fault lies at Calculator.java source file at line 113 in the file. This is where you call the method log() which requires an argument of type 'double' which is located in Math class log method where the two arguments are 'int' and 'int'.
    However, in your call, you inflect the reference 'result' as the product of the method call in which the 1st argument is also 'result'
    That in itself is bad design. It's like saying "Joe is the product of Mike (who uses Joe)."
    Memory-wise, this could cause possible leaks.

  • Java Calculator, Minus & multiplication button gets wrong answer?

    import java.awt.event.*;
    import java.applet.Applet;
    import javax.swing.*;
    import java.awt.*;
    public class calc extends JApplet implements ActionListener
         JTextField input = new JTextField("");
         JButton numbers[] = new JButton[10];
         JButton add = new JButton("+");
         JButton equals = new JButton("=");
         JButton minus = new JButton("-");
        JButton multiply = new JButton("*");
        JButton divide = new JButton("/");
        JButton clear = new JButton("AC");
         int num1 = 0;
         int num2 = 0;     
         String oper = " ";
         public void init()
              setLayout(null);
              setBackground(new Color(227,131,125));          
              Design();
         public void Design()
              int x = 1;
              int y= 1;
              int wi = 10;
              int he = 50;
              input.setSize(250,30);
              input.setLocation(10,10);
              add(input);
              add.setSize(80,30);
              add.setLocation(280,50);
              add.addActionListener(this);
              add(add);
              minus.setSize(80,30);
              minus.setLocation(280,90);
              minus.addActionListener(this);
              add(minus);
              multiply.setSize(80,30);
              multiply.setLocation(280,130);
              multiply.addActionListener(this);
              add(multiply);
              divide.setSize(80,30);
              divide.setLocation(280,175);
              divide.addActionListener(this);
              add(divide);
              equals.setSize(80,30);
              equals.setLocation(190,175);
              equals.addActionListener(this);
              add(equals);
             clear.setSize(80,30);
              clear.setLocation(100,175);
              clear.addActionListener(this);
              add(clear);
              while(x<=10)
                   if (x==10)
                   numbers[x-1] = new JButton("0");
                   numbers[x-1].setSize(80,30);
                   numbers[x-1].setLocation(wi,he);
                   //numbers[x-1].setBackground();
                   else
                   numbers[x-1] = new JButton(Integer.toString(x));
                   numbers[x-1].setSize(80,30);
                   numbers[x-1].setLocation(wi,he);
                   wi = wi + 90;
                        if(x%3==0)
                             he = he + 40;
                             wi = 10;
                   numbers[x-1].addActionListener(this);
                   add(numbers[x-1]);          
                   x++;
         public void actionPerformed(ActionEvent act)
              int x = 0;
              while(x<10)
                   if(act.getSource().equals(numbers[x]))
                        if(x==9)
                             input.setText("0");
                        else                    
                        input.setText(Integer.toString(x+1));
                   x++;
              if (act.getSource().equals(add))
                   num1 = Integer.parseInt(input.getText());
              else if(act.getSource().equals(equals))
                   num2 = Integer.parseInt(input.getText());
                   input.setText(Integer.toString(num1 + num2));
                   if (act.getSource().equals(minus))
                   num1 = Integer.parseInt(input.getText());
                   oper = "minus";
              else if(act.getSource().equals(equals))
                   num2 = Integer.parseInt(input.getText());
                   if(oper.equals("minus"))
                        input.setText(Integer.toString(num1 - num2));
                   if (act.getSource().equals(multiply))
                   num1 = Integer.parseInt(input.getText());
                   oper = "multiply";
              else if(act.getSource().equals(equals))
                   num2 = Integer.parseInt(input.getText());
                   if(oper.equals("multiply"))
                        input.setText(Integer.toString(num1 * num2));
    The addition button is working, but i cant seem to make minus and multiply button work, they get wrong answer when i use them.. what could bee the problem with my code

    Sorry, but I don't see a simple fix in this code here (Hopefully I'm wrong and someone else will see this, but I don't) Because of this, I recommend that you fully scrap this code and start over from square one. I don't think that you really "see" your logic here. To help you see what you are trying to do, you need to separate your logic from your GUI. Try to build a non-gui calculator that works via simple console menu. Once you get this working, then use this code to create a GUI calculator.

  • I having trouble running a GUI window

    I am trying to view a GUI calculator that I made with java, it compiles with no errors but when I run it I get this message:
    Exception in thread "main" java.awt.HeadlessException:
    No X11 DISPLAY variable was set, but this program performed an operation which requires it.
    at java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:159)
    at java.awt.Window.<init>(Window.java:317)
    at java.awt.Frame.<init>(Frame.java:419)
    at java.awt.Frame.<init>(Frame.java:384)
    at javax.swing.JFrame.<init>(JFrame.java:150)
    at GUIcalc.<init>(GUIcalc.java:20)
    at GUIcalc.main(GUIcalc.java:15)
    It is preventing me from veiwing the calculator, I don't know what to do.
    Also I am trying to install NetBean 4.1 so that I don't have to use putty.exe to make programs, but I keep getting this message when I try to start the DeployTool:
    JAVA VIRTUAL MACHINE LAUNCHER
    Could not find the main class. Program will exit.
    What should I do or download to make it work?
    Thank You.

    Sort of like NetBeans, but I found it to be a lot easier to use. Installed and ran right away without any problems.

  • HOW to make a text apper from the other side in a Textfield

    am trying to allow the text come from the other side in a textfield. eg..look at the caculator on your windows OS. see how the textfield appears from the left. any suggestions.???

    this are the errors on ur code
    even after i imported javax.swing.text
    NoteSizeFilter.java:2: cannot find symbol
    symbol: class DocumentFilter
    public class NoteSizeFilter extends DocumentFilter {
    ^
    NoteSizeFilter.java:14: cannot find symbol
    symbol : class FilterBypass
    location: class NoteSizeFilter
    public void insertString(FilterBypass fb, int offs, String str, AttributeSet a)
    ^
    NoteSizeFilter.java:14: cannot find symbol
    symbol : class AttributeSet
    location: class NoteSizeFilter
    public void insertString(FilterBypass fb, int offs, String str, AttributeSet a)
    ^
    NoteSizeFilter.java:15: cannot find symbol
    symbol : class BadLocationException
    location: class NoteSizeFilter
    throws BadLocationException {
    ^
    NoteSizeFilter.java:23: cannot find symbol
    symbol : class FilterBypass
    location: class NoteSizeFilter
    public void replace(FilterBypass fb, int offs, int length, String str, AttributeSet a)
    ^
    NoteSizeFilter.java:23: cannot find symbol
    symbol : class AttributeSet
    location: class NoteSizeFilter
    public void replace(FilterBypass fb, int offs, int length, String str, AttributeSet a)
    ^
    NoteSizeFilter.java:24: cannot find symbol
    symbol : class BadLocationException
    location: class NoteSizeFilter
    throws BadLocationException {
    ^
    NoteSizeFilter.java:16: operator + cannot be applied to FilterBypass.getDocument.getLength,int
    if ((fb.getDocument().getLength() + str.length()) <= maxCharacters) {
    ^
    NoteSizeFilter.java:16: operator <= cannot be applied to <nulltype>,int
    if ((fb.getDocument().getLength() + str.length()) <= maxCharacters) {
    ^
    NoteSizeFilter.java:17: cannot find symbol
    symbol : variable super
    location: class NoteSizeFilter
    super.insertString(fb, offs, str, a);
    ^
    NoteSizeFilter.java:25: operator + cannot be applied to FilterBypass.getDocument.getLength,int
    if ((fb.getDocument().getLength() + str.length() - length) <= maxCharacters) {
    ^
    NoteSizeFilter.java:25: operator - cannot be applied to <nulltype>,int
    if ((fb.getDocument().getLength() + str.length() - length) <= maxCharacters) {
    ^
    NoteSizeFilter.java:26: cannot find symbol
    symbol : variable super
    location: class NoteSizeFilter
    super.replace(fb, offs, length, str, a);
    ^
    NoteSizeFilter.java:28: cannot find symbol
    symbol : variable super
    location: class NoteSizeFilter
    super.replace(fb, offs, length, str, a);
    ^
    NoteSizeFilter.java:31: cannot find symbol
    symbol : variable super
    location: class NoteSizeFilter
    super.replace(fb, 0, fb.getDocument().getLength(), parsed, a);
    ^
    15 errors
    C:\Java Files\GUI\Calculator>

  • Run a calculation and keep Log-GUI uptodate

    Hello,
    I have some troubles trying to run a thread and keep the GUI uptodate at the same time. The idea initial idea is:
    - In the "normal" GUI there are two buttons to "Start" and "Cancel" a bigger calculation task.
    - Once the "Start" Button is clicked, the calculation is started
    - Since the user might want to cancel it, the "Cancel" Button should be able to abort the calculation process
    - The Calculation itself should be able to write results into a log-JTable which is also part of the "normal" GUI
    I tried to put the calculation in a separate Thread and then wait for the results:
    startTheThread();
    while threadNotFinished() {
    this.wait(500);
    Sadly- the GUI isn't refreshed neither can the user click the Cancel Button :-(.
    I guess this problem is quite common, but I haven't found anything helpful yet. Can someone help me with this please?
    Regards,
    Peter Vincent

    Make sure you are doing your calculation out side the event thread and updating via invokeAndWait or invokeLater.
    Probably better was to handel the threading, but here is an example...
    import java.util.*;
    import javax.swing.*;
    import javax.swing.table.*;
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.border.*;
    import javax.swing.event.*;
    public class ThreadedTable extends JFrame implements ActionListener, Runnable
        DefaultTableModel model;
        Thread t;
        JButton start;
        JButton stop;
        int lastEntry;
        boolean kill;
        public ThreadedTable()
            this.setDefaultCloseOperation( EXIT_ON_CLOSE );
            String[] names = {"Col - 1","Col - 2"};
            model = new DefaultTableModel(names, 0  );
            JTable table1 = new JTable( model );
            Container pane = getContentPane();
            pane.setLayout(new BorderLayout());
            JScrollPane s1 = new JScrollPane( table1 );
            JPanel buttonPanel = new JPanel();
            start = new JButton( "Start");
            start.addActionListener( this );
            buttonPanel.add( start );
            stop = new JButton( "Stop");
            stop.addActionListener( this );
            buttonPanel.add( stop );
            pane.add(s1, BorderLayout.CENTER);
            pane.add(buttonPanel, BorderLayout.SOUTH );;
            pack();
        public static void main(String args[])
            ThreadedTable test = new ThreadedTable();
            test.show();
        public void run()
            Vector v = new Vector();
            v.addElement( "col 1 Data");
            v.addElement( "counter = "+lastEntry++);
            model.addRow(v);
         * Invoked when an action occurs.
        public void actionPerformed(ActionEvent e)
            if( e.getSource().equals( start ) )
                if( t != null )
                    while( t.isAlive() )
                        kill = true;
                        try
                            Thread.sleep( 120 );
                        catch( Exception exc )
                            exc.printStackTrace();
                kill = false;
                Runnable runner = new Runnable()
                    public void run()
                        while( !kill )
                            try
                                SwingUtilities.invokeAndWait( ThreadedTable.this );
                                Thread.sleep( 1000 );
                            catch( Exception exc )
                                exc.printStackTrace();
                t=new Thread( runner );
                t.start();           
            else if( e.getSource().equals( stop ) )
                kill = true;

  • Discoverer: "CASE WHEN...." in calculations won't show anything in GUI !?!?

    Hi all!
    I have a report in Discoverer Plus (Version 10.1.2.48.18) which contains 2 columns: One with actual spendings and one with budget figures. I want to make a third column which holds actual spendings in percentage of the budget. To do this, I need to make a calculation similar to:
    CASE WHEN SUM(budget) <> 0 THEN SUM(spendings)/SUM(budget) ELSE NULL END
    However, when I apply this calculation to the third column, my report don't return any numbers at all in any column.
    What am I doing wrong? -- Is this a bug, and how should I solve my problem?
    ~Morten

    I can get something out if I do this (applying an aggregate function to it all):
    SUM(CASE WHEN budget <> 0 THEN spendings/budget ELSE NULL END)
    However, this is wrong (Summarizing these percentages doesn't give any meaning).
    SQL lookes something like this:
    SELECT /*+ NOREWRITE */ o100448.ACCOUNT as E100451,(decode((ADD_MONTHS(o100862.DATE1,-4)),null,to_date(null, 'MMDDYYYY'),to_date(to_char(trunc((ADD_MONTHS(o100862.DATE1,-4)),'YYYY'),'YYYY') || '01','YYYYMM'))) as E101004,MAX(o100448.ACCOUNTNUM) as as100473_100451_NEW,CASE WHEN ( SUM(o100862.BUDGET) ) <> 0 THEN ( SUM(o100862.AMOUNT) )/( SUM(o100862.BUDGET) ) ELSE NULL END as C_1,( SUM(o100862.BUDGET) )*o100448.SIGN as C_3,( SUM(o100862.AMOUNT) )*o100448.SIGN as C_2,GROUPING_ID(o100448.ACCOUNT,o100448.SIGN,(decode((ADD_MONTHS(o100862.DATE1,-4)),null,to_date(null, 'MMDDYYYY'),to_date(to_char(trunc((ADD_MONTHS(o100862.DATE1,-4)),'YYYY'),'YYYY') || '01','YYYYMM')))) as GID
    FROM TANGO.TANGO_ACCOUNTS o100448,
    TANGO.TANGO_SUMS o100862
    WHERE ( (o100862.ORG = o100448.ORG AND o100862.ACCOUNTNUM = o100448.SUBACCOUNTNUM))
    AND (o100448.ACCOUNTNUM BETWEEN 30000 AND 79999)
    AND (o100862.DIM = '50')
    AND (o100448.ORG = 'bru')
    GROUP BY GROUPING SETS(( o100448.ACCOUNT,o100448.SIGN,(decode((ADD_MONTHS(o100862.DATE1,-4)),null,to_date(null, 'MMDDYYYY'),to_date(to_char(trunc((ADD_MONTHS(o100862.DATE1,-4)),'YYYY'),'YYYY') || '01','YYYYMM'))) ),( o100448.ACCOUNT,(decode((ADD_MONTHS(o100862.DATE1,-4)),null,to_date(null, 'MMDDYYYY'),to_date(to_char(trunc((ADD_MONTHS(o100862.DATE1,-4)),'YYYY'),'YYYY') || '01','YYYYMM'))) ))
    HAVING (GROUP_ID()=0)
    ORDER BY GID DESC;
    I tried to fire this SQL up in TOAD (or whatever SQL-tool you might have), and columns C_2 and C_3 are empty. Seems like I'm doing something awfully wrong here.....
    Any ideas? (There must be some SQL sharks out there ;-p)
    ~Morten

  • How preferred size of JAVA GUI is calculated when the parent component is invisible?

    Hi
    Suppose a Panel has a tabbed pane with two tabs inside it.  If I do setVisible(false) for 2nd tab but not for its child components,
    Will the size of child component's of 2nd tab be considered to calculate the preferred size of the TopPanel ?
    Similarly,  If a Panel has a sub-panel and sub-panel has few child components. If sub-panel is invisible but its child components are visible, they will not be shown on the screen.
    In this case, Will the sizes of sub-panel's child components be considered for calculating the preferred size of the outer panel ?
    Please let me know
    Thanks in advance.

    Are you talking about Java or another language?
    However, when I run this report, JVM tries to allocate these 10 MB objects, but causes an Allocation Failure (AF). Java does get such an error. It can get an OutOfMemoryError.
    At this point, the unusable heap size due to fragmentation is ~100 MB. Again Java doesn't get unusable heap space as the GC will repack the memory to remove fragmentation.
    - is 10 MB object size okay? Is it normal to have object size of 10 MB?In Java it is normal.
    - How can I reduce the fragmentation in the memory?Use Java.

  • A calculation intensive GUI application

    Hi all,
    I am developing a GUI application that involves drawing of a graph layout, with nodes and links..
    i get through the graph drawing part and I lay out the nodes and edges correctly. My real concerns are adding the user interactions to this graph drawing.
    I want to allow the user to drag nodes around the panel, be able to track which node they are visiting or which edge the mouse is currently present on. Also on selecting a particular node I wish that all the others are drawn in gray.
    My thoughts are to provide the user with a toolbar, that will have buttons for each of the interaction possible, Hide, Gray, Reorder, etc.. also I need to locate where the mouse pointer is. So for that I provide a panel and as the mouse moves over each line, i populate a label in one of the bottom panels.
    I am presently locating that the mouse is on a particular edge / node by simply iterating through the vector and using a contains (Point p ) test. But this is really intensive as my application has 1000s of edges. So everytime the mouse moves, I have to check for most of them to determine which node/edge is the mouse over.
    I have to do the same computations when the mouse is clicked as i will be selected a particular node/edge on a mouse click.
    Will the command pattern be helpful in my case, I can represent each of the interactions as a command?
    How can I make my application efficient and not check through the entire 1000s of elements to determine where the mouse is ? ( i do break out once i find a match but that is still ridiculous)
    Will SwingInvoker be of any help ? I do need the return value so dispatching the event to a separate thread might not really help as I have to wait for the computation to complete..
    lastly are there classic tutorials / design pattern examples for such applications where there is a lot of interactivity with the drawn components?
    Thanks in advance...

    Your greatest asset in this situation is probably going to be the LabVIEW examples. Go to the help menu, look for the examples, and just start searching. You may have to look at a few examples to find all of the elements you need.
    Once you have gone through those, just post here if you have any more questions.

  • Shipping cost not getting calculated in CRM IC webclient for a region

    HI all,
    I have an issue where when we create an order, the shipping cost is not getting calculated automatically.. and so we are having to manually enter the shipping cost..this is happening only for Apac regions. for all other regions it seems to be working. but the shipping cost is getting calculated in R/3. can anyone provide input for this?
    Also, what factors determine the shipping cost?
    Thank you,
    Preethy

    what price conditions determine your cost in R/3?
    might be easier to use the CRM gui and create the order in crmd_order and look at the conditions.  Unless you set it up there is no plant in CRM (just vendor) so if your cost is tied to your plant, I'm not sure how you would get this without a possible rfc call to R/3.

Maybe you are looking for

  • NTFS Folder not showing up in OS X

    I've got this 320 GB external harddrive with a NTFS Partition that I use with Windows. It works fine with Windows, and I know that it is only possible to read files with OS X. My problem is that there is one folder with my itunes and videos that only

  • How to display an applet in a html page

    I can't get my beautifull new applet displayed in IE. I just get a grey box instead of my applet... Can someone send me the correct code for displaying an applet under IE ??? Thanks in advance, Menno.

  • Best Practice: Update OWB 10.2.0.1 to 10.2.0.3 ?

    Hey OWB-Guys, I've searched the forum and metalink, but I could not find what I'm looking for. I want to update my OWB from version 10.2.0.1 to 10.2.0.3 (I'm working on WinXP Pro Sp2, so I can't use 10.2.0.4, right?). Our system architecture will cha

  • Authentication on a Wireless Network

    Hi all, I have 2 standalone networks to be deployed in a hotel area on ground and 20th floor. We have a 5M internet link provided by the ISP for the users. I will be usingAIR-WLC4402-12-K9 with AIR-LAP1142N-N-K9 for providing wireless connectivity. I

  • Canon EOS 550D JPEGs don't show white balance EXIF info in Aperture

    I have 23,000 photos in my iPhoto library which I would eventually like to transfer to Aperture. I've experimented with importing just a few photos from iPhoto so that I can practise using Aperture before I go over to it completely, but have a proble