Please tell me what is wrong with my code.

Hi there,
I have developed a simple class alpPhoto.java in which I can find out the width height of a image using ImageIcon. Everything works fine when I deploy myApp.ear file on my OC4J - NT version. But when I deploy myApp.ear file on my OC4J - Unix version, the jsp that I call alpPhoto got hung until timed out. Here is the code of alpPhoto:
import java.io.*;
import java.util.* ;
import javax.swing.*;
import java.net.*;
public class alpPhoto {
private int ImgWidth ;
public void setImgWidth(int width )
this.ImgWidth = width ;
public int getImgWidth()
return this.ImgWidth ;
private int ImgHeight ;
public void setImgHeight(int height)
this.ImgHeight = height ;
public int getImgHeight()
return this.ImgHeight;
private String ImgURL ;
public void setImgURL(String strURL){
this.ImgURL = strURL ;
public String getImgURL()
return this.ImgURL ;
public alpPhoto(String imgPath) throws Exception
if( imgPath == null || imgPath == ""){
throw new Exception("The physical path to the photo is empty.") ;
}else{
System.out.println( imgPath);
File myFile = new File(imgPath) ;
if(myFile.exists()){
URL myURL = myFile.toURL() ;
setImgURL( myURL.toString() );
ImageIcon image = new ImageIcon(myURL);
setImgWidth( image.getIconWidth() );
setImgHeight( image.getIconHeight()) ;
}else{
throw new Exception(imgPath + " does not exist.\n\n") ;
Here is how I call this class in my jsp file:
<%
alpPhoto curPhoto = new alpPhoto(imgPath) ;
int width = curPhoto.getImgWidth();
int height = curPhoto.getImgHeight();
%>
where the "imgPath" is the parameter passed from other jsp file.
I wonder if there is bug or obviously what is the main difference between the OC4J - NT version and the OC4J - Unix version.
Thanks in advance.
Henry

Not sure if this will help, but take a look at the MediaTracker class. The MediaTracker will wait until an image is completely loaded before continuing. This will ensure that you width/height values are always non-zero.

Similar Messages

  • HT201401 my iphone screen has got line please tell me what's wrong with my phone

    i have bought recently iphone 5s from apple store but now my iphone screen has got line please tell me what's wrong with my phone

    It is not working cprrectly.
    Take it back.

  • Can someone please tell me what's wrong with the Inside of my iPad Charger? *Picture Included

    It won't charge my iPad. So I wanted to take a good look inside and see what's wrong with it. But I don't know anything about these wires. Here's the Pic of it.
    http://oi39.tinypic.com/2ed5yl2.jpg
    http://oi42.tinypic.com/5btptt.jpg
    http://oi39.tinypic.com/ih8rq1.jpg
    PLEASE HELP. It would be a Big Help

    That's unfortunate, because it would appear that the cable is pretty much toast. If it wasn't before, it pretty much is now that you've cracked it open.
    Either borrow one, or bite the bullet and buy one locally. You're not getting anywhere with that one.

  • FB4 doesn't tell me what's wrong with my code. Not even letting me trace().

    Attached is my code that run well but the problem is, I know there is something wrong with my code since the dropdown list isn't populated unlike the textarea. Doesn't even put anything on the output panel when i do trace()-ing.
    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
    xmlns:s="library://ns.adobe.com/flex/spark"
    xmlns:mx="library://ns.adobe.com/flex/halo"
    creationComplete="application1_initializeHandler(event)">
    <s:layout>
    <s:BasicLayout/>
    </s:layout>
    <fx:Script>
    <![CDATA[
    import mx.events.FlexEvent;
    protected function application1_initializeHandler(event:FlexEvent):void
    var xml:XML;
    var xmlLoader:URLLoader = new URLLoader();
    xmlLoader.load(new URLRequest('data/places.xml'));
    xmlLoader.addEventListener(
    Event.COMPLETE,
    function (e:Event):void {
    xml = new XML(e.target.data);
    trace(xml.place[0].barangay.descendants().toXMLString());
    for each (var pro:Object in xml.places.place)
    dp.dataProvider.addItem({province:pro.province});
    ta.text = xml.place[0].barangay.descendants().toXMLString();
    ]]>
    </fx:Script>
    <s:DropDownList id="dp"
    labelField="province"
    width="197"
    x="10" y="10"/>
    <s:TextArea x="198" y="186" id="ta" editable="true"/>
    </s:Application>

    @jdesko:
    i tried both with or w/o the nightly builds, still i can't see anything on the output panel using trace and the above code doesn't trigger the Error Panel why the dropdown list isn't populated..
    @Jason: thanks. the prob was with my e4x expression but with the console output thingy, now i run in debug mode but got the error:
    C:\Windows\System32\Macromed\Flash\NPSWF32.dll
    Flash Builder cannot locate the required debugger version of Adobe Flash Player. You might need to install the debugger version of the Flash Player or reinstall Flash Builder.
    Do you want to try to debug with the current version?
    I thought FB4 has this already in the package. I'm wondering why it asks for like this.

  • Can someone please tell me what's wrong with my feed?

    iTunes isn't updating with my most recent podcast, and I can't see what I've done wrong on my feed.
    Can someone help
    www.ministryofslam.com/feed
    https://itunes.apple.com/gb/podcast/ministry-slam-pro-wrestling/id301376618
    It's "Bonus Podcast" that isn't appearing

    At the beginning of the entry for the episode of 21 November you have the opening 'item' tag in twice. This is sufficient to render the feed unreadable and so it's turning up empty when subscribing and the Store is not updating.

  • Please tell me what's wrong with this paypal buy code?

    <form id="form1" name="form1" method="post" action="">
              <p><form action="https://www.paypal.com/cgi-bin/webscr" method="post">
    <input type="hidden" name="cmd" value="_s-xclick">
    <input type="hidden" name="hosted_button_id" value="PBG8WAM6N6G2S">
    <table>
    <tr><td><input type="hidden" name="on0" value="&quot;Showtime&quot;-paper print">&quot;Showtime&quot;-paper print</td></tr><tr><td><select name="os0">
        <option value="1-11x14">1-11x14 $50.00</option>
        <option value="1-12x18">1-12x18 $65.00</option>
        <option value="1-16x20">1-16x20 $90.00</option>
        <option value="1-24x36">1-24x36 $170.00</option>
    </select> </td></tr>
    </table>
    <input type="hidden" name="currency_code" value="USD">
    <input type="image" src="https://www.paypal.com/en_US/i/btn/btn_buynowCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!">
    <img alt="" border="0" src="https://www.paypal.com/en_US/i/scr/pixel.gif" width="1" height="1">
    </form>
    When I insert this code and try the "buy buttton" nothing happens.  My website is www.ritacortesi.com.  Paypal does not really have a good support website.

    HTML and/or DW Tutorials, and other information links that I have saved
    http://validator.w3.org/
    http://www.w3schools.com/
    http://www.hotscripts.com/
    http://webdesignledger.com/
    http://www.adobe.com/devnet/
    http://www.scriptarchive.com/
    http://www.htmldog.com/guides/
    http://www.htmlcodetutorial.com/
    http://alistapart.com/topics/code
    http://www.how-to-build-websites.com/
    http://css.maxdesign.com.au/floatutorial/
    Download User Guide as PDF for easy search
    http://www.adobe.com/support/documentation
    http://www.ianr.unl.edu/internet/mailto.html
    http://lynda.com/ Hours of videos. (must pay)
    http://apptools.com/examples/pagelayout101.php
    http://www.thesitewizard.com/archive/css.shtml
    http://www.projectseven.com/tutorials/index.htm
    If not PDF (link above) an online guide to read
    http://livedocs.adobe.com/en_US/Dreamweaver/9.0/
    Nate's Forms http://www.mindpalette.com/scripts/
    Customizing the layouts that come with CS3 (VIDEO)
    http://www.adobe.com/designcenter/video_workshop/?id=vid0155
    FormMail http://www.bebosoft.com/products/formstogo/index.php
    For those using MySQL - Installing PHP and MySQL on Windows XP
    http://www.webassist.com/professional/products/solutionrecipes.asp
    Community MX lessons http://www.communitymx.com/abstract.cfm?cid=3D074
    http://www.adobe.com/cfusion/designcenter/search.cfm?product=Dreamweaver&go=Go
    The Contact Form Solution Pack is only $29.99. To learn more, visit
    http://www.webassist.com/go/cfsp
    Web advisor extension to DW
    Date and Time through Javascript http://www.mediacollege.com/internet/javascript/date-time/
    Tutorial for building your first website:
    http://www.adobe.com/devnet/dreamweaver/articles/first_website_pt1.html
    Tutorial on building a dynamic website (one with a database):
    http://www.adobe.com/devnet/dreamweaver/articles/first_dynamic_site_pt1.html
    HTM Color Codes
    http://www.visibone.com/
    or http://html-color-codes.com/
    or http://www.pagetutor.com/common/bgcolors1536.html
    or http://www.geocities.com/SiliconValley/Network/2397/

  • Can someone tell me what's wrong with this code....

    I apologize in advance for anyone who isn't a Steelers fan...
    import java.awt.*;
    import javax.swing.*;
    public class myJPanel extends JPanel
         public myJPanel()
              setBackground(Color.white);
         JLabel label1 = new JLabel();
         label1.setText("Ben Roethlisberger #7 Age 23");
         add(label1);
         JButton jb1;
         ImageIcon imageBen = new ImageIcon("Ben.JPG");
         jb1 = new JButton(imageBen);
         add(jb1);
         JLabel label3 = new JLabel();
         label3.setText(whatIsUp());
         add(label3);
         for(i=0;i<20;i++)
         String whatIsUp()
              int n = 0;
              double nn = 0;
              String b = "......";
              nn = (Math.random() * 6);
              n = (int)nn;
              if (n == 0)
                   b = "Ben Roethlisberger throws a touchdown pass to Hines Ward.";
                   JButton jb2;
              ImageIcon imageHines = new ImageIcon("Hines.jpg");
              jb2 = new JButton(imageHines);
              add(jb2);
              if (n == 1) b = "Ben Roethlisberger throws a touchdown pass to Antwaan Randle El.";
              if (n == 2) b = "Ben Roethlisberger throws a touchdown pass to Heath Miller.";
              if (n == 3) b = "Ben Roethlisberger throws a touchdown pass to Cedrick Wilson.";
              if (n == 4) b = "Ben Roethlisberger throws a touchdown pass to Jerame Tuman.";
              if (n == 5) b = "Ben Roethlisberger hands off to Jerome Bettis for a touchdown.";
              return b;
    Everything is ok if i take the for loop out, but for some reason everything just gets screwed up if I have that for loop in there. And these are the error messages I'm getting.
    'illegal start of type (line 21)' and '<identifier> expected (line 48)'
    Thanks in advance for your help...

    Hey I'm sorry but this is only my second week doing
    Java. Do you think you could explain that more or
    give me an example??
    Bad Version (like yours but simplified)
    public class Sample{
      public static void main(String args[]){
        for(int i=0;i<20;i++){
          String whatIsUp(){
             return "Doc";
          System.out.println(?);// I am not even sure how to write this voodoo part
    }Good Version
    public class Sample{
      public static void main(String args[]){
        for(int i=0;i<20;i++){
          String aString = whatIsUp();
          System.out.println(aString);
      String whatIsUp(){
        return "Doc";
    }

  • Could you tell me what is wrong with this code?

    import java.io.*;
    import java.lang.String;
    import java.util.*;
    import java.util.Properties;
    import java.io.InputStream;
    public class EStoreClient2 {
    private void insertTable (Vector value) {
         insertStmnt.setString(1, (String)value.get(0)
    public void static main (String args[]) {
         Vector argument = new Vector();
         if (args.length > 0) {
              for (int i=1; i < args.length; i++) {
                   argument.add(args);
                   System.out.println("<argument[]> = " + args[i]);
              EStoreClient2 estore = new EStoreClient2();
              if (args[0].equalsIgnoreCase("-insertitem"))
              estore.insertTable(argument);
    but it gives me
    EStoreClient2.java:18: Method get(int) not found in class
    java.util.Vector.
    insertStmnt.setString(1, (String)value.get(0));

    EStoreClient2.java:18: Method get(int) not found in
    class
    java.util.Vector.
    insertStmnt.setString(1,
    nsertStmnt.setString(1, (String)value.get(0));The method get(int) was introduced into the Vector class starting at JDK1.2. You must be using an earlier version of the JDK.

  • I can't figure out what's wrong with this code

    First i want this program to allow me to enter a number with the EasyReader class and depending on the number entered it will show that specific line of this peom:
    One two buckle your shoe
    Three four shut the door
    Five six pick up sticks
    Seven eight lay them straight
    Nine ten this is the end.
    The error message i got was an illegal start of expression. I can't figure out why it is giving me this error because i have if (n = 1) || (n = 2) statements. My code is:
    public class PoemSeventeen
    public static void main(String[] args)
    EasyReader console = new EasyReader();
    System.out.println("Enter a number for the poem (0 to quit): ");
    int n = console.readInt();
    if (n = 1) || (n = 2)
    System.out.println("One, two, buckle your shoe");
    else if (n = 3) || (n = 4)
    System.out.println("Three, four, shut the door");
    else if (n = 5) || (n = 6)
    System.out.println("Five, six, pick up sticks");
    else if (n = 7) || (n = 8)
    System.out.println("Seven, eight, lay them straight");
    else if (n = 9) || (n = 10)
    System.out.println("Nine, ten, this is the end");
    else if (n = 0)
    System.out.println("You may exit now");
    else
    System.out.println("Put in a number between 0 and 10");
    I messed around with a few other thing because i had some weird errors before but now i have narrowed it down to just this 1 error.
    The EasyReader class code:
    // package com.skylit.io;
    import java.io.*;
    * @author Gary Litvin
    * @version 1.2, 5/30/02
    * Written as part of
    * <i>Java Methods: An Introduction to Object-Oriented Programming</i>
    * (Skylight Publishing 2001, ISBN 0-9654853-7-4)
    * and
    * <i>Java Methods AB: Data Structures</i>
    * (Skylight Publishing 2003, ISBN 0-9654853-1-5)
    * EasyReader provides simple methods for reading the console and
    * for opening and reading text files. All exceptions are handled
    * inside the class and are hidden from the user.
    * <xmp>
    * Example:
    * =======
    * EasyReader console = new EasyReader();
    * System.out.print("Enter input file name: ");
    * String fileName = console.readLine();
    * EasyReader inFile = new EasyReader(fileName);
    * if (inFile.bad())
    * System.err.println("Can't open " + fileName);
    * System.exit(1);
    * String firstLine = inFile.readLine();
    * if (!inFile.eof()) // or: if (firstLine != null)
    * System.out.println("The first line is : " + firstLine);
    * System.out.print("Enter the maximum number of integers to read: ");
    * int maxCount = console.readInt();
    * int k, count = 0;
    * while (count < maxCount && !inFile.eof())
    * k = inFile.readInt();
    * if (!inFile.eof())
    * // process or store this number
    * count++;
    * inFile.close(); // optional
    * System.out.println(count + " numbers read");
    * </xmp>
    public class EasyReader
    protected String myFileName;
    protected BufferedReader myInFile;
    protected int myErrorFlags = 0;
    protected static final int OPENERROR = 0x0001;
    protected static final int CLOSEERROR = 0x0002;
    protected static final int READERROR = 0x0004;
    protected static final int EOF = 0x0100;
    * Constructor. Prepares console (System.in) for reading
    public EasyReader()
    myFileName = null;
    myErrorFlags = 0;
    myInFile = new BufferedReader(
    new InputStreamReader(System.in), 128);
    * Constructor. opens a file for reading
    * @param fileName the name or pathname of the file
    public EasyReader(String fileName)
    myFileName = fileName;
    myErrorFlags = 0;
    try
    myInFile = new BufferedReader(new FileReader(fileName), 1024);
    catch (FileNotFoundException e)
    myErrorFlags |= OPENERROR;
    myFileName = null;
    * Closes the file
    public void close()
    if (myFileName == null)
    return;
    try
    myInFile.close();
    catch (IOException e)
    System.err.println("Error closing " + myFileName + "\n");
    myErrorFlags |= CLOSEERROR;
    * Checks the status of the file
    * @return true if en error occurred opening or reading the file,
    * false otherwise
    public boolean bad()
    return myErrorFlags != 0;
    * Checks the EOF status of the file
    * @return true if EOF was encountered in the previous read
    * operation, false otherwise
    public boolean eof()
    return (myErrorFlags & EOF) != 0;
    private boolean ready() throws IOException
    return myFileName == null || myInFile.ready();
    * Reads the next character from a file (any character including
    * a space or a newline character).
    * @return character read or <code>null</code> character
    * (Unicode 0) if trying to read beyond the EOF
    public char readChar()
    char ch = '\u0000';
    try
    if (ready())
    ch = (char)myInFile.read();
    catch (IOException e)
    if (myFileName != null)
    System.err.println("Error reading " + myFileName + "\n");
    myErrorFlags |= READERROR;
    if (ch == '\u0000')
    myErrorFlags |= EOF;
    return ch;
    * Reads from the current position in the file up to and including
    * the next newline character. The newline character is thrown away
    * @return the read string (excluding the newline character) or
    * null if trying to read beyond the EOF
    public String readLine()
    String s = null;
    try
    s = myInFile.readLine();
    catch (IOException e)
    if (myFileName != null)
    System.err.println("Error reading " + myFileName + "\n");
    myErrorFlags |= READERROR;
    if (s == null)
    myErrorFlags |= EOF;
    return s;
    * Skips whitespace and reads the next word (a string of consecutive
    * non-whitespace characters (up to but excluding the next space,
    * newline, etc.)
    * @return the read string or null if trying to read beyond the EOF
    public String readWord()
    StringBuffer buffer = new StringBuffer(128);
    char ch = ' ';
    int count = 0;
    String s = null;
    try
    while (ready() && Character.isWhitespace(ch))
    ch = (char)myInFile.read();
    while (ready() && !Character.isWhitespace(ch))
    count++;
    buffer.append(ch);
    myInFile.mark(1);
    ch = (char)myInFile.read();
    if (count > 0)
    myInFile.reset();
    s = buffer.toString();
    else
    myErrorFlags |= EOF;
    catch (IOException e)
    if (myFileName != null)
    System.err.println("Error reading " + myFileName + "\n");
    myErrorFlags |= READERROR;
    return s;
    * Reads the next integer (without validating its format)
    * @return the integer read or 0 if trying to read beyond the EOF
    public int readInt()
    String s = readWord();
    if (s != null)
    return Integer.parseInt(s);
    else
    return 0;
    * Reads the next double (without validating its format)
    * @return the number read or 0 if trying to read beyond the EOF
    public double readDouble()
    String s = readWord();
    if (s != null)
    return Double.parseDouble(s);
    // in Java 1, use: return Double.valueOf(s).doubleValue();
    else
    return 0.0;
    Can anybody please tell me what's wrong with this code? Thanks

    String[] message = {
        "One, two, buckle your shoe",
        "One, two, buckle your shoe",
        "Three, four, shut the door",
        "Three, four, shut the door",
        "Five, six, pick up sticks",
        "Five, six, pick up sticks",
        "Seven, eight, lay them straight",
        "Seven, eight, lay them straight",
        "Nine, ten, this is the end",
        "Nine, ten, this is the end"
    if(n>0)
        System.out.println(message[n]);
    else
        System.exit(0);

  • What is wrong with this code? on(release) gotoAndPlay("2")'{'

    Please could someone tell me what is wrong with this code - on(release)
    gotoAndPlay("2")'{'
    this is the error that comes up and i have tried changing it but it is not working
    **Error** Scene=Scene 1, layer=Layer 2, frame=1:Line 2: '{' expected
         gotoAndPlay("2")'{'
    Total ActionScript Errors: 1 Reported Errors: 1
    Thanks

    If you have a frame labelled "2" then it should be:
    on (release) {
        this._parent.gotoAndPlay("2");
    or other wise just the following to go to frame 2:
    on (release) {
         this._parent.gotoAndPlay(2);
    You just had a missing curly bracket...

  • What's wrong with my code?

    I don't have a lot of time for explanation. Somebody please tell me what's wrong with the following code.
    import java.nio.*;
    import java.io.*;
    public class GettingAnInteger {
         public static void main(String args[]) {
              IntBuffer intBuf = new IntBuffer.allocate(10);
              int x;
              x = intBuf.get();
              System.out.print(x);
    }Thanks!!!

    Why wouldn't you include the keyword new?http://java.sun.com/docs/books/tutorial/
    http://java.sun.com/learning/new2java/index.html
    http://javaalmanac.com
    http://www.jguru.com
    http://www.javaranch.com
    Bruce Eckel's Thinking in Java
    Joshua Bloch's Effective Java
    Bert Bates and Kathy Sierra's Head First Java

  • Please tell me what's wrong

    I want this button to be clicked and pop up with a movie clip
    at the coordinates (27.9,0) so this code should do it... alas it
    doesn't. please tell me what's wrong within it. I'm using Adobe CS3
    with AS3 on a mac. the movie clip is called doc_patient and the
    button is doc_butt

    heh... heh... just the code you gave doesn't work though. The
    compiler errors come up on the x and y lines saying "1120: Access
    of undefined property. What is EVERYTHING i'd need to write if my
    button is called: button and the movie clip is called: clip
    coordinates (0,0)?

  • My iPhone 4S won't turn on it's been off for two days now. I tried charging it but it makes a noise every 8 seconds,holding the buttons down and also plugging it to a computer. I need help on what to do or if anybody can tell me what's wrong with my phone

    My iPhone 4S won't turn on it's been off for two days now. I tried charging it but it makes a noise every 8 seconds,holding the buttons down and also plugging it to a computer. I need help on what to do or if anybody can tell me what's wrong with my phone

    Yes ive tried a different charger and it also nothing shows when i plug it in just makes a noise

  • What's wrong with my code? please help....

    when display button is clicked it must diplay the remarks but it didn't happen...
    what's wrong with my code? please help
    here is my code.....
    import java.applet.Applet;
    import java.awt.*;
    import java.awt.event.*;
    public class Area extends Applet implements ItemListener,ActionListener
         {Label arlbl = new Label("AREA");
          Choice archc = new Choice();
          Label extlbl = new Label("EXPENDITURE TYPE");
          CheckboxGroup extchk = new CheckboxGroup();
              Checkbox fchk = new Checkbox("FOOD",extchk,true);
              Checkbox schk = new Checkbox("SHELTER",extchk,false);
              Checkbox echk = new Checkbox("EDUCATION",extchk,false);
              Checkbox uchk = new Checkbox("UTILITIES",extchk,false);
          Label exalbl = new Label("EXPENDITURE AMOUNT");
          TextField exatf = new TextField("",20);
          Label remlbl = new Label("REMARKS");
          TextField remtf = new TextField("",30);
          Button disbtn = new Button("DISPLAY");
          Button resbtn = new Button("RESET");
          String display;
          public void init()
              {add(arlbl);
               archc.add("MANILA");
               archc.add("MAKATI");
               archc.add("QUEZON");
               archc.add("PASAY");
               add(archc);
               archc.addItemListener(this);
               add(extlbl);
               add(fchk);
               fchk.addItemListener(this);
               add(schk);
               schk.addItemListener(this);     
               add(echk);
               echk.addItemListener(this);
               add(uchk);
               uchk.addItemListener(this);
               add(exalbl);
               add(exatf);
               add(remlbl);
               add(remtf);
               add(disbtn);
               disbtn.addActionListener(this);
               add(resbtn);
               resbtn.addActionListener(this);
         public void itemStateChanged(ItemEvent ex)
              {int n = archc.getSelectedIndex();
               if(n==0)
                   {if(fchk.getState())
                         {exatf.setText("10000.00");
                         display = archc.getSelectedItem();
                   if(schk.getState())
                        {exatf.setText("15000.00");
                        display = archc.getSelectedItem();
                   if(echk.getState())
                        {exatf.setText("24000.00");
                        display = archc.getSelectedItem();
                   if(uchk.getState())
                        {exatf.setText("8500.00");
                        display = archc.getSelectedItem();
              if(n==1)
                   {if(fchk.getState())
                        {exatf.setText("5000.00");
                        display = archc.getSelectedItem();
                   if(schk.getState())
                        {exatf.setText("11000.00");
                        display = archc.getSelectedItem();
                   if(echk.getState())
                        {exatf.setText("7500.00");
                        display = archc.getSelectedItem();
                   if(uchk.getState())
                        {exatf.setText("24000.00");
                        display = archc.getSelectedItem();
              if(n==2)
                   {if(fchk.getState())
                        {exatf.setText("13000.00");
                        display = archc.getSelectedItem();
                   if(schk.getState())
                        {exatf.setText("7000.00");
                        display = archc.getSelectedItem();
                   if(echk.getState())
                        {exatf.setText("27000.00");
                        display = archc.getSelectedItem();
                   if(uchk.getState())
                        {exatf.setText("6000.00");
                        display = archc.getSelectedItem();
              if(n==3)
                   {if(fchk.getState())
                        {exatf.setText("6000.00");
                        display = archc.getSelectedItem();
                   if(schk.getState())
                        {exatf.setText("9000.00");
                        display = archc.getSelectedItem();
                   if(echk.getState())
                        {exatf.setText("15000.00");
                        display = archc.getSelectedItem();
                   if(uchk.getState())
                        {exatf.setText("19000.00");
                        display = archc.getSelectedItem();
         public void actionPerformed(ActionEvent e)
              {if(e.getSource() == disbtn)
                    {String amtstr = exatf.getText();
                     int amt = Integer.parseInt(amtstr);
                        {if(amt > 8000)
                             {remtf.setText(display + " IS ABOVE BUDGET");
                        else
                             {remtf.setText(display + " IS BELOW BUDGET");
              if(e.getSource() == resbtn)
                   {archc.select(0);
                   fchk.setState(true);
                   schk.setState(false);
                   echk.setState(false);
                   uchk.setState(false);
                   exatf.setText("");
                   remtf.setText("");
    Edited by: lovely23 on Feb 28, 2009 11:24 PM

    Edit: thanks for cross-posting this question on another forum. I now see that I wasted my time trying to study your code in the java-forums to help you with an answer that had already been answered elsewhere (here). Do you realize that we are volunteers, that our time is as valuable as yours? Apparently not. Cross-post again and many here will not help you again. I know that I won't.

  • I have i pad 2 ios 4.3.1 i want to update it to 4.3.3 but i get error msg 3194 can you tell me what's wrong with apple some people talking about apple don't veryfiy 4.3.3 anymore thanks alot

    i have i pad 2 ios 4.3.1 i want to update it to 4.3.3 but i get error msg 3194 can you tell me what's wrong with apple some people talking about apple don't veryfiy 4.3.3 anymore thanks alot

    4.3.5 is the current version, so that is the version that iTunes will download, not 4.3.3
    In terms of error 3194, have you got the latest version of iTunes on your computer ? - http://support.apple.com/kb/TS3694#error3194

Maybe you are looking for

  • Getting information from SRM !

    Hi Experts, Can anyone help me find the tables which get updated during the below mentioned processes in SRM. 1) In transaction PPOSA_BBP the details of the cost center, delivery address etc. assigned on a position level or org unit level is stored i

  • Selection sentance in ABAP

    Hi, I would like to write the sentance like this. If  parameter 1 (cost centre)  OR parameter 2 (order)  on selection screen is entered. DO THIS. ELSE. DO THAT. ENDIF. Now my code is like this, but the system doesn't recognize it .... IF S_KOSTL OR S

  • How do i make photos largest to send in email?larger is shaded

    i am trying to send larger photos through email,when the size shows up it has the largest shaded when i send it the photos are small.i have a g5 mac running 10.5.thank you in advance

  • Message and facetime on mac

    it wont sign in, help!

  • Basic (and I mean basic) java problem with a simple hello world script

    I have a simple cut-and-paste html page and java class in my /home/jc158027/java directory. jc158027> cat HelloWorld.java import java.applet.*; import java.awt.*; public class HelloWorld extends Applet{ Label helloLabel = new Label ("Hello World"); p