One Click - two times the same event?

Hello guys, i have a little problem...
When I click on my button it seems to be that the event handler method is run two times. I cant understand why - its happening at all buttons. can anyone help me?
GUI.java
public void actionPerformed(ActionEvent event) {
transmit();                  // transmit the textfields
p.translate();               // translate it to xml
html = p.newHTML();          // translate the xml to html
status.setText("<html>"+html);  // set the translatet html in the preview panel
taHtml.setText(html);  // set the translatet html in the text area     
The problem is that it appears two times in both, the area and the label.
Here is the other code, if it helps.
public String newHTML() {
          String tmp = xMLToHTMLParser.translate(xml);
          return tmp;
public String translate(String delivered) {
               xml = delivered;
               html += "<b>";
               try {
               html += xml.substring(xml.indexOf("<Headline>")+10, xml.indexOf("</Headline>"));
               catch(Exception e) {}  // When nothing is in the Headline do nothing.
html += "</p>\n \n";
               return html;
          }Thnak you so much for you help!
Toby

Ok, here is the transmit():
    /** Transmits the content of the Textfields to the Parser */
    private void transmit() {
         String Logoname = phases[phaseChoices.getSelectedIndex()];
         p.setLogoURL("http://www.destinations2discover.com/images/icons/"+Logoname);  // All icons are already saved on the Server
         p.setHeadline(tfHeadline.getText());
         // It's very tricky to get the correct dates in :)
         // First Step: transfer the correct Items, for next Step see Parser.java
         if( !tfAdditional.getText().equalsIgnoreCase("" )) {
              try {
                   p.setDateline(tfAdditional.getText());
              catch(Exception e) {
              p.setDateline ("T Y P E C A S T   E R R O R   IN   D A T E L I N E   A D D I T I O N A L");
         /*else*/ if(( (!tfStartDay.getText().equalsIgnoreCase("")) &&  (!tfStartMonth.getText().equalsIgnoreCase("")) &&  (!tfStartYear.getText().equalsIgnoreCase("" )) && (!tfEndDay.getText().equalsIgnoreCase("")) &&  (!tfEndMonth.getText().equalsIgnoreCase("")) &&  (!tfEndYear.getText().equalsIgnoreCase("")) )) {
              try {
              p.setDateline ( Integer.parseInt(tfStartDay.getText()), Integer.parseInt(tfStartMonth.getText()), Integer.parseInt(tfStartYear.getText()), Integer.parseInt(tfEndDay.getText()), Integer.parseInt(tfEndMonth.getText()), Integer.parseInt(tfEndYear.getText()) );
          catch(Exception e) {
               p.setDateline ("T Y P E C A S T   E R R O R   IN   D A T E L I N E   S T A R T  /  E N D");
         else if(((!tfStartDay.getText().equalsIgnoreCase("")) &&  (!tfStartMonth.getText().equalsIgnoreCase("")) &&  (!tfStartYear.getText().equalsIgnoreCase("" )) ) ){
              try {
                   p.setDateline ( Integer.parseInt(tfStartDay.getText()), Integer.parseInt(tfStartMonth.getText()), Integer.parseInt(tfStartYear.getText()) );
          catch(Exception e) {
               p.setDateline ("T Y P E C A S T   E R R O R   IN   D A T E L I N E   S T A R T");
//-->FIX::  Add Annual Event Checkbox      if(!btnAnnual.getText().equalsIgnoreCase("StartDay"))
         if(!tfImageURL.getText().equalsIgnoreCase("")) {
              p.setImageURL(tfImageURL.getText());
         if(!tfText.getText().equalsIgnoreCase("")) {
              //p.setText(tfText.getText());
              p.setText(taTxt.getText());
         if(!tfHyperlink.getText().equalsIgnoreCase("")) {
              p.setHyperlinkURL(tfHyperlink.getText());
    }And here is the whole actionPerformed - just to make sure i have the listener not twice.
public void actionPerformed(ActionEvent event) {
        if ("comboBoxChanged".equals(event.getActionCommand())) {
            //Update the icon to display the new phase.
            phaseIconLabel.setIcon(images[phaseChoices.getSelectedIndex()]);
        // Set the article ID from the radio buttons
        else if (event.getSource() == rbFOM) {
            p.setID(1);
        else if (event.getSource() == rbInsider){
             p.setID(2);
        else if (event.getSource() == rbMustSee){
             p.setID(3);
        else if (event.getSource() == rbMustDo){
             p.setID(4);
        else if (event.getSource() == rbMustExperience){
             p.setID(5);
        else if (event.getSource() == rbActivity){
             p.setID(6);
        else if (event.getSource() == sendContent) {
             transmit();                  // transmit the textfields
             p.translate();               // translate it to xml
             html = p.newHTML();          // translate the xml to html
             status.setText("<html>"+html);  // set the translatet html in the preview panel
             taHtml.setText(html);  // set the translatet html in the text area     
             // write in html in line.html and xml in line.xml file
             try  {
             FileOutputStream fos = new FileOutputStream( "line.html" );
            fos.write( html.getBytes() );
            fos.close();
            catch ( Exception e ) { System.out.println(e); }
            xml = p.getXML();
            try  {
             FileOutputStream fos2 = new FileOutputStream( "line.xml" );
            fos2.write( xml.getBytes() );
            fos2.close();
            catch ( Exception e ) { System.out.println(e); }
            show = true;     // workaround
        else if (event.getSource() == addContent) {
             transmit();                  // transmit the textfields
             p.translate();               // translate it to xml
             html = p.newHTML();          // translate the xml to html
             status.setText("<html>"+html);  // set the translatet html in the preview panel
             taHtml.setText(html);  // set the translatet html in the text area     
             // write in html in line.html and xml in line.xml file
             try  {
             FileOutputStream fos = new FileOutputStream( "line.html" );
            fos.write( html.getBytes() );
            fos.close();
            catch ( Exception e ) { System.out.println(e); }
            xml = p.getXML();
            try  {
             FileOutputStream fos2 = new FileOutputStream( "line.xml" );
            fos2.write( xml.getBytes() );
            fos2.close();
            catch ( Exception e ) { System.out.println(e); }
            show = true;
        else if (event.getSource() == showInIE) {
             if(show) {   // workaround
             try  {
                  File fd= new File("");
                path = fd.getAbsolutePath();
                path = "C:\\Program Files\\Internet Explorer\\iexplore.exe "  + path +  "\\line.html";
                System.out.println(path);  // debug
                  //     Runtime.getRuntime().exec("C:\\Program Files\\Internet Explorer\\iexplore.exe \"C:\\Dokumente und Einstellungen\\intern\\Eigene Dateien\\code kopie\\text2XML\\text2Destination\\line.html\"");
                  Runtime.getRuntime().exec(path);
             catch ( Exception e ) { System.out.println(e); }
             show = false;   // workaround
             showInIE.disable();
             else if(show = false) {  // workaround
                  show = true;   // workaround
        }This problem is not only at the Button with "sendContent" it is also with "addContent' and "showInIE".
Thank you two.

Similar Messages

  • How to have two times the same iTunes library ?

    My parents are separated, so I have two computers (one with my father and the other one with my mother) and all my music is in the computer with my mother, I want to have the same iTunes library to my father how I should do?

    Not an easy one. Maybe you can try on both computers ) if they are both Macs or both PC to setup your iTunes Librery to be on an external USB drive. Under Windows make sure the USB HDD always mount with the same letter. Both computers should be Authorized for your account.

  • I bought an audio book on iTunes and it charged me for two of the same book and downloaded two.  How do I get my money back for one of them?

    I purchased an audio book on iTunes store and was charged for two and downloaded two of the same book.  How do I get my money back for the second one?

    Try contacting iTunes support via this page : http://www.apple.com/support/itunes/contact/ - click on Contact iTunes Store Support on the right-hand side of the page, then Purchases, Billing & Redemption
    Note that audiobooks are currently a one-time only download from the store, so you may want to take a backup copy of it

  • Using more than one front panel at the same time

    I have a main program where I can call sub vi’s and then the sub vi’s front panel opens.
    I want to use/see/operate more than one front panel at the same time. How I can do it?
    For example when I close the main program it won’t close before I close all the sub vi’s front panels.
    I use event case to call these sub vi’s. Can I close all vi's using one button?

    I wouldn't use subVIs for display, at least not if you plan to have them open all the time. Instead, I would suggest that you have one loop with a FP VI which will talk to the FP all the time and will pass to the data to the other loops through a variable or a functional global.
    Then, you can use a tab control to organize your display. If there is no specific reason for not having the graphs in the same VI, you can use a tab control to organize it. If you can't, you can also use subpanels to display the VIs and put several subpanels in your VI.
    If you still want to display the VIs seperately, you can control their positions and sizes through their proerty nodes, but I don't think there's any reason for this.
    To learn more, I suggest you read the LabVIEW style guide. I think it has some tips about application design.
    Try to take over the world!

  • Workflow sending 20 email notifications every one hour for the same event

    Hi Experts,
    We had an issue on a clientu2019s prod system that the workflow triggered the same event 20 times in one hour. Later, a client has resolved the issue by removing the information from the workflow administration and reentering it back again. The workflow administration contains email settings, web settings, workflow roles, and active workflow maintenance. Although, the issue has been resolved but a client still needs to know how that happened. I would like to get some helpful opinions on how this happened because I am very new to the workflow. I would really appreciate your opinions.
    Thank you
    Don P.

    Hi Sue,
    Thank you for your response. I am not sure if the event has been triggered erroneously. The client told us that it didn't happen in the dev system when he tested it, but it only happen in the prod system. This project went live a little bit over a year ago without any issues, but it just happened the first on 6/22.
    The event is about to notify the user to review a new incident report (EHS), and it's same event id for all 20 email notifications. We will a client to look into their system about how this event raised?, what does the event log reveal? and if he uses the event queue. Again, thanks for your response.
    -Don P.

  • TS3367 I have two IPhones and one IPad all with the same Apple ID. I can call facetime between the two IPhones, but I cannot call the IPAD from either of the IPhones and when I call my IPhone from the IPad it rings my wife's IPhone after briefly calling m

    I have two IPhones and one IPad all with the same Apple ID. I can call facetime between the two IPhones, but I cannot call the IPAD from either of the IPhones and when I call my IPhone from the IPad it rings my wife's IPhone after briefly calling mine.

    Each device needs a separate address. Use an email address (gmail.com) on the iPad.
    Using FaceTime http://support.apple.com/kb/ht4319
    Troubleshooting FaceTime http://support.apple.com/kb/TS3367
    The Complete Guide to FaceTime + iMessage: Setup, Use, and Troubleshooting
    http://tinyurl.com/a7odey8
    Troubleshooting FaceTime and iMessage activation
    http://support.apple.com/kb/TS4268
    Using FaceTime and iMessage behind a firewall
    http://support.apple.com/kb/HT4245
    iOS: About Messages
    http://support.apple.com/kb/HT3529
    Set up iMessage
    http://www.apple.com/ca/ios/messages/
    Troubleshooting Messages
    http://support.apple.com/kb/TS2755
    Setting Up Multiple iOS Devices for iMessage and Facetime
    http://macmost.com/setting-up-multiple-ios-devices-for-messages-and-facetime.htm l
    FaceTime and iMessage not accepting Apple ID password
    http://www.ilounge.com/index.php/articles/comments/facetime-and-imessage-not-acc epting-apple-id-password/
    Unable to use FaceTime and iMessage with my apple ID
    https://discussions.apple.com/thread/4649373?tstart=90
    For non-Apple devices, check out the TextFree app https://itunes.apple.com/us/app/text-free-textfree-sms-real/id399355755?mt=8
    How to Send SMS from iPad
    http://www.iskysoft.com/apple-ipad/send-sms-from-ipad.html
     Cheers, Tom

  • How do I have the same "events" on two Macs?

    I have the "family pack" and just installed on both Macs. I have the same exact pictures on both Macs. I organized all the events on one Mac and now I would like to have the same events on the second Mac.
    On the previous version of iPhoto, I simply would copy com.apple.iPhoto.plist from the first Mac and copy it to the next Mac. Then all my preferences (e.g., file names, roll names, etc.) would match. This method does not seem to work on iPhoto 08.
    Any suggestions?

    John:
    You could use iPhoto Library Manager and copy the events from one library to another like this. The demo shows an event being copies but it works the same for albums.
    You'll need to connect the Macs so you have access to the libraries and then IPLM will do the job.
    Do you Twango?
    TIP: For insurance against the iPhoto database corruption that many users have experienced I recommend making a backup copy of the Library6.iPhoto database file and keep it current. If problems crop up where iPhoto suddenly can't see any photos or thinks there are no photos in the library, replacing the working Library6.iPhoto file with the backup will often get the library back. By keeping it current I mean backup after each import and/or any serious editing or work on books, slideshows, calendars, cards, etc. That insures that if a problem pops up and you do need to replace the database file, you'll retain all those efforts. It doesn't take long to make the backup and it's good insurance.
    I've written an Automator workflow application (requires Tiger), iPhoto dB File Backup, that will copy the selected Library6.iPhoto file from your iPhoto Library folder to the Pictures folder, replacing any previous version of it. It's compatible with iPhoto 08 libraries. You can download it at Toad's Cellar. Be sure to read the Read Me pdf file.

  • Can multiple PCs access one remote panel at the same time?

    I've written a program in labview 7.1 to monitor/control a labview application running in the test cell through Remote Panel. I and my coworker can remotely monitor and/or control this labview application individually. But if my coworker has the remote panel displayed on his PC and I try to get the remote panel on my PC, I get a labview error (63) as below:
    "LabVIEW:  Serial port receive buffer overflow.
    LabVIEW:  The network connection was refused by the server."
    My question is: Can multiple PCs access one remote panel at the same time?
    Thanks in advance!
    Y

    Sorry I wasn't clear. The remote panel license is separate from the number of LabVIEW development licenses. Pricing information on remote panel licenses can be found here.

  • I can not transfer date from one hard drive to another, I keep getting an error because I have two of the same file names and one file name is in caps and I cant change the file name

    can not transfer date from one hard drive to another, I keep getting an error because I have two of the same file names and one file name is in caps and I cant change the file name. My original external has an error and needs to be reformatted but I dont want to lose this informations its my entire Itunes library.

    Sounds like the source drive is formatted as case sensitive and the destination drive is not. The preferred format for OS X is case insensitive unless there is a compelling reason to go case sensitive.
    Why can't you change the filename? Is it because the source drive is having problems?  If so is this happening with only one or two or a few files? If so the best thing would be to copy those over individually and then rename them on the destination drive.
    If it is more then you can do manually and you can't change the name on the source you will have to reformat the destination as case sensitive.
    Btw this group is for discussion of the Support Communities itself, you;d do better posting to Lion group. I'll see if a host will move it.

  • HT1338 How can i use my data on windows or mac when i use one of them in the same time?

    Hi,
    i have a Mac book with 2 operating system, ( Windows& mac). How can i use my data on windows or mac when i use one of them in the same time?
    Thank you

    The following article(s) may help you.
    Resolving duplicate calendars
    Resolving duplicate contacts

  • If I already have a particular app under one apple Id and I purchase the same app under a different Id for the same device, will it overwrite or replace the previous or will I have two of the same app on the same device??

    If I already have a particular app under one apple Id and I purchase the same app under a different Id for the same device, will it overwrite or replace the previous or will I have two of the same app on the same device?? 
    I'm asking because I purchased an app with an id that has been cancelled so I cannot update that particular app. I can purchase the app with my new id but I don't want to do so if its going to erase all the data I have with the previous purchase...

    Figured it out. Thanks.

  • Please can someone explain how to retrieve deleted text, I was clearing old text when one came through at the same time so was also deleted.

    Can someone please tell me how to retrieve deleted text. i was clearing old texts when a new one came through at the same time and was deleted also.  My last update was  iOS 8.1.2

    You restore from a backup that was created after the text was received but before it was deleted.
    But if you literally deleted it right after it came in, then it's not recoverable.  Have the other person resend the text.

  • When putting an event on my iPhone calendar and the time, when it goes to iCloud to my laptop or iPad calendar the times are different.  How can I make the time the same?

    When putting an event and the time on my iPhone calendar, when it goes to iCloud to my laptop or iPad calendar the times are different.  How can I make the time the same?

    Welcome to the Apple Community.
    Is the calendar you are adding events to on the phone an iCloud calendar.

  • When I click on the download button the box with Run or save comes up then disappears before I can click on it. Then nothing happens. I have tried this numerous times the same thing keeps happening

    Question
    When I click on the download button the box with Run or save comes up then disappears before I can click on it. Then nothing happens. I have tried this numerous times the same thing keeps happening> edit

    Maybe these will help:
    https://discussions.apple.com/message/17677533#17677533
    https://discussions.apple.com/message/18324129#18324129
    https://discussions.apple.com/message/18203126#18203126

  • I have photos from several cameras of the same event, how do I combine them?

    I have photos from several cameras of the same events.  How can I sort them together, three pics of the same horse from three cameras side by side; I can't move pics from one camera source to another in a folder.

    Languare is critical since it is all we have to communicate with
    Folders in iPhoto do not hold photos - folders hold only other folders or albums
    If you are speaking of events then you simply merge the events (drag one onto another or select two or more and use the merge events command - for the photos to be "side by side" the three camera's time/date setting will have to be identical as photos will be sorted by time/date - if they are not you can correct by selecting the photos in an event (before merging) and using the adjust time and date command or you can make a smart album for the camera and select the photos and use the adjust time and date command
    LN

Maybe you are looking for

  • Item not relevant for billing-Batch Split

    Dear all Item is not relevant for billing for Batch Split item. i have checked item category, item category determination and copy control. The scenario is working fine for local and export but for deemed export the item is not relevant for billing P

  • Error at Import_Proper : Some clarifications?

    Hi, I am facing this error while installing the ST-A/PI (01J_ECC600) support packages. I am getting stuck at IMPORT_PROPER with error. The error message read as follows. Action Logs import phase 'IMPORT_PROPER' (08.05.2010, 08:22:03) Error during exe

  • Ask the Expert: BYOD with Identity Services Engine

    with Cisco Expert Bernardo Gaspar Welcome to the Cisco Support Community Ask the Expert conversation. This is an opportunity to learn and ask questions about Identity Services Engine (ISE) and its various usage scenarios and integrations such as BYOD

  • No Apple ID in App Store

    We bought a 2e hand MacBook Air and we want to use the App Store for upgrading to Maverick. In iTunes our Aplle ID is oke in the App Store they told us the PC is not ours. How can we connect the pc wit our Apple ID. The MacBook wasn't stolen we allre

  • Why does my Wacom tablet only make straight lines with the pencil & brush tool even WITHOUT shift?

    I have Photoshop CS3 on Mac OSX 10.5.8 on a white MacBook and I'm using a Wacom CTE-630, and I always had the correct drivers. Yesterday I discovered that the brush and pencil tools were incapable of doing anything but a dot or a straight line while