How do I get rid of a NullPointerException (error)?

Hello,
I believe that this chuck of code (leftAction) is the culprit for my error message - I know an object is required but what?
public void NumberedList()
  entries.setText(" There are " + count + "in the list");
    public void leftAction() // saves entries and displays entry count
       storage[count]= input.getText();
       NumberedList();
      win.repaint();

I should include the whole thing sorry - I thought that just the snipet I gave was enough
ublic class ListOfStrings extends A3ButtonHandler
        private A3ButtonWindow win;   
        private ATextField input;   
        private ALabel entries;   
        private ALabel answer;   
        private ALabel[] display;  // Declares a variable that can hold an array
        private String[] storage;
        private int count = 0;
     * Constructs the handler object, the 3-button
     * window and populates the window.
    public ListOfStrings()
        // Create the 3-button window
        win = new A3ButtonWindow(this);
        win.setLeftText("Save");
        win.setMidText("Display");
        win.setRightText("Discard");
        display = new ALabel[10];
       display[0] = new ALabel(200, 100, 200, 20); // Populate first element
        display[1] = new ALabel(200, 125, 200, 20);
        display[2] = new ALabel(200, 150, 200, 20);
        display[3] = new ALabel(200, 175, 200, 20);
        display[4] = new ALabel(200, 200, 200, 20);
        display[5] = new ALabel(200, 225, 200, 20);
        display[6] = new ALabel(200, 250, 200, 20);
        display[7] = new ALabel(200, 275, 200, 20);
        display[8] = new ALabel(200, 300, 200, 20);
        display[9] = new ALabel(200, 325, 200, 20);
        display[9] = new ALabel(200, 350, 200, 20); // Populate tenth element
        storage = new String[9];
      input = new ATextField(125,400,150,25);
      input.place(win);
      input.setFontSize(12);
   private void Status(int m)
        entries.setText("There are " + m + " entries in the list");
   private void Error()
        entries.setText("message");
        return;
public void NumberedList()
  entries.setText(" There are " + count + "in the list");
    public void leftAction() // saves entries and displays entry count
       storage[count]= input.getText();
       NumberedList();
      win.repaint();
     * Displays saved entries
    public void midAction()
  for (int i = 0; i < storage.length; i++)
    display.setText(storage[i]);
public void rightAction()
Rob

Similar Messages

  • How can I get rid of a 1202 error when downloading products from itunes

    How can I get rid of an 1202 error when downloading products from itunes?

    You have probably downloaded the Norton program which is one of the least desirable helpmates you can invite in.
    Read this thread and follow the suggestions by Thomas R, one of our gurus in this field.
    https://discussions.apple.com/message/20005609#20005609

  • RoboHelp 11 - When previewing topics from within the project, a script error displays: 'HHComponent Activator' is undefined. How do you get rid of this script error?

    RoboHelp 11
    When previewing topics from within the project, a script error diplays: 'HHComponent Activator' is undefined.
    How do you get rid of this script error?

    Hi there
    Have you tried clicking Help > Updates and applying the service release?
    If not, I'd start with that.
    Cheers... Rick

  • How do I get rid off "metric evaluation errors"

    How do I get rid off "metric evaluation errors"
    In my Home page in Enterprise Manager Grid Control site,
    I have some errors under "All Targets Alerts".
    They are defined as "metric evaluation errors"
    How do I get rid of them?
    All errors are "Collection Failure" during installation of Agent....

    If you click on the "metric evaluation error" icon or the number to its right (depending on the screen you're looking at) it will usually direct you to the metric and an error of what's broke.
    The hard part is usually trying to fix it as the error messages most times aren't too helpfull.

  • How can I get rid of Shockwave Player Error message? I'm not trying to play anything, but it pops up whenever I reset my Safari.

    I keep getting a message on my Mac saying:
    Shockwave Player Error
    To view the movie, open your browser in the 32-bit mode.
    1) In Safari, select applications/safari in the Finder and click more info
    2) Ensure that Open in 32-bit mode is selected
    3) Re-launch the browser.
    I did this, and selected the open in 32-bit mode but it's still giving me this message.
    Interestingly, it does this every time I reset my Safari (which I do upon closing Safari), UNLESS I unclick the "Remove all website data" item box - then I don't get this weird shockwave player error message.
    I would like to know either how to get rid of the error message (stop it from popping up) or how to download/install shockwave in case I need it.

    I am having this issue whenever I go to Safari privacy preferences tab it pops up this same error window repeatedly, over and over, even if I don't acknowledge the first one... it just keeps adding the error window one on top of the other. (a little offset like opening multiple browser windows).
    If I switch to a different application it may even keep popping them up keeping them on top all the time.
    I navigated to Library/Internet Plug-ins and there was nothing in it.

  • How can I get rid of strobe player error messages?

    Can someone please tell me where I can go in the source to get rid of the error messages I keep seeing in the Strobe player such as 'Error #2032' prior to a live stream and 'Stream not found' once the live stream is done?.  These error messages are annoying our customers and we need help getting rid of them.
    Thanks,

    We solved this problem by changing the source code. There is a function named alert() which prints the messsage to the screen. We comment out it and then compiled again. http://osmf.org/dev/osmf/specpdfs/building-osmf.pdf here is specification for compiling strobe player. In addition to these there is an option to pass the player 'verbose'. 'verbose:false' closes Error codes, but prints explanations.

  • How do I get rid of a script error?

    I keep getting this error message:  A script on this page may be busy, or it may have stopped responding. You can stop the script now, or you can continue to see if the script will complete.  Script: https://s3.amazonaws.com/hostjs/load.js:1
    It seems to be preventing me to access email in Outlook and some other web sites.  I cant click on the link.
    Randy Hammond

    Hi Randy, all I get at that link is...
    <Error><Code>AccessDenied</Code><Message>Access Denied</Message><RequestId>107242350D564325</RequestId><HostId>PyhVVdCU0Ghyq6+Q wBMLv4kSl4Hu8SwSXynySON9GBfsMRWAafSFMN6QB9vcVcve</HostId></Error>
    But anyway, all you can do is quit the script, try another browser, or upgade your OS version maybe.

  • How do I get rid of a Runtime Error on PSE11?

    Am running PSE11 on Vista.
    Saw a resolution to change the MediaDataBase file, but cannot find that in the PSE11 file listing.

    Hi Randy, all I get at that link is...
    <Error><Code>AccessDenied</Code><Message>Access Denied</Message><RequestId>107242350D564325</RequestId><HostId>PyhVVdCU0Ghyq6+Q wBMLv4kSl4Hu8SwSXynySON9GBfsMRWAafSFMN6QB9vcVcve</HostId></Error>
    But anyway, all you can do is quit the script, try another browser, or upgade your OS version maybe.

  • How do I get rid of the following error message?

    Firefox could not install the search plugin from "file:///C:/Documents%20and%20Settings/Owner/Application%20Data/Mozilla/Firefox/Profiles/3fjzcxfk.default/FCTB/%7B51ef49d2-624b-4194-8b97-1c468e9b0efe%7D/60497/547b6f0419da8aa93c7ae24e435eed4c" because an engine with the same name already exists.

    What search engine are you trying to install?
    You either already have it as one on the default search engines or installed it yourself.
    You can find user installed search engines in the searchplugins folder in the Firefox profile folder.
    You can use this button to go to the currently used Firefox profile folder:
    *Help > Troubleshooting Information > Profile Directory: Show Folder (Linux: Open Directory; Mac: Show in Finder)
    *http://kb.mozillazine.org/Profile_folder_-_Firefox

  • How do I get rid of a download error? Reloading or "retry" doesn't work. Please advise. Thanks.

    Reload doesn't work. Retry don't work. Is it possible to reset it?

    Hi Steelers,
    Please rename the hosts file to hosts.old
    Below is the location of hosts file
    Windows: C:\Windows\System32\drivers\etc
    Mac: Open the finder window click on go and choose go to folder and type /etc and press enter
            Rename the hosts file.
    Then try to launch creative cloud again and try,
    Thanks

  • How can I get rid of files that cannot be imported error message

    Hello, this is my first post. I am a new mac user. I have imported my jpgs from an external hard drive which was in the most part successful, however, 14 of the files appear to be corrupted and every time I open iphoto9, I get the error message, '14 of your files could not be imported, would you like to import them now?' I have tried choosing both options yes and no and it then writes error message telling me it has created recovered photos folder. When you go to this folder it is empty and every time I restart iphoto, I get the same message. I have tried deleting all the files and re-importing only to find that the number of corrupted files has now doubled. I have also deleted the iphotos library recovered photo folders to no avail. I have tried creating a new library and importing the files to that but the same problem occurred. How can I get rid of this repeated error as I am now up to recovered folder number 47! Help!

    P Robbins
    Welcome to the Apple user to user assistance forums
    quit iPhoto and right click (control click) on the iPhoto library (in the pictures folder by default) and select the show package contents command - find the import (or importing) folder and drag it to the desktop and launch iPhoto - you should be fine now - open the import(ing) folder on your desktop and if there are any photos you want import them then trash the folder
    LN

  • I ran a scan on my computer and it found 1,288 errors how can I get rid of them?

    I did a scan test on my desktop and found that I have run sections(10 errors), user software settings(195 errors), system software settings(867 errors), ActiveX and com sections(78 errors), file associations(92 errors), uninstall sections(known as add-remove programs in control panel found(28 errors), current user file extensions(3 errors), shared Dlls(1 error) and in the missing help files (4 errors). How can I get rid of all these errors?

    As this is not a Firefox question, you should consider asking this in a forum that specializes in Windows questions, such as Eileen's Lounge - http://eileenslounge.com/

  • When I login on my When I sign in to a site on my ipad using my email address as ID a short cut of my email address comes up. How can I get rid of it?

    When I sign in to a site on my iPad using my email address as ID a short cut of my email address comes up. How can I get rid of it?

    You can edit keyboard shortcuts in Settings>General>Keyboard>Shortcuts>Edit.

  • I have a Australian iTunes account and want to switch to using the u.s store as I now live there, I cannot do this because I have $1.41 still in the oz account an image to have a zero balance to change stores, how can I get rid of the $1.41?

    I want to switch to the u.s store as I now live in the us, I cannot switch stores because my balance is $1.41 in the oz store and needs to be zero, how can I get rid of the $1.41 when everything costs more or less than that? I do not have a credit card on the oz iTunes account an I cannot use my us one to top it up.
    HELP

    Click here and request assistance.
    (60992)

  • I want to switch stores from Japan to USA. I used to have an iTunes card, and there's 15 YEN left in my account, how can I get rid of that so I can start purchasing in the US store using my new credit card?

    I want to switch stores from Japan to USA. I used to have an iTunes card, and there's 15 YEN left in my account, how can I get rid of that so I can start purchasing in the US store using my new credit card?

    I can't seem to find an app that costs my available balance. iTunes said I need to spend it ALL before I can change stores. This means I cannot totally change stores.... Hopeless.

Maybe you are looking for

  • Itunes 5.0 = Ipod plugged in = blue screen crash

    Just installed Itunes 5.0. Now with my Ipods (two) plugged into my computer it crashes and will not work. Unbelievable never had this happen before thought it was a virus checked that, uninstalled, reinstalled, no luck. The only way to get the comput

  • Adobe Media Encoder CC 2014.0.1 (8.0.1) update is now available

    Today, the Adobe Media Encoder CC 2014.0.1 (8.0.1) update was released. This update addresses several bugs, adds support for 4K in H.264, new and simplified presets for YouTube, and other features. Read about the details of the update here: http://bl

  • How do I embed an image in a post here?

    How do I embed an image in a post here?

  • Spry Accordion always active

    When the Accordion is not focused, it is gray. How to disactivate this function? I want that it is always active. it forgives me, my English is not good.

  • Yahoo mail sync issue after upgrade to iOS 5

    After i have upgraded to iOS 5 my emails from Yahoo are a month off. Only the emails from a month before are synchronized. As an example, today 10/24 I can see the emails from until 9/13. Any ideas on how to fix this?