Running two program instances

Please help!!!
I am developing a swing program which communicates modem via serial port. I used javax.comm package in the program. After coding, I compile all the class file into a jar file and use a .bat file to execute the program. If I just run one instance of the program, everything seems fine. But if I launch another instance of the program, problems occur. Only one set of swing components appear on two instance, either on one or on another. (i.e. the interface contains one button, one label and one textField. After I launch two instances, one instance's interface may contain the button and the label and another instance may contain just the textfield.). Upon closing the program, a log file was saved. The log as follow:
An unexpected exception has been detected in native code outside the VM.
Unexpected Signal : EXCEPTION_ACCESS_VIOLATION occurred at PC=0x6d043c7a
Function name=Java_sun_java2d_loops_DefaultComponent_IntIsomorphicCopyLibrary=D:\jdk1.3.1_01\jre\bin\awt.dll
Current Java thread:     at sun.java2d.loops.DefaultComponent.IntIsomorphicCopy(Native Method)
javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(SystemEventQueueUtilities.java:124)     at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:154)
     at java.awt.EventQueue.dispatchEvent(EventQueue.java:337)
# The exception above was detected in native code outside the VM
# Java VM: Java HotSpot(TM) Client VM (1.3.1_01 mixed mode)
Any help will be appreciated.
William

Thank you very much for your response.
I compressed my program into a .jar file. The batch file I used contains "javaw.exe -jar Diagnostic.jar" to execute the program.
According to the log file, It must have an execption that the program does not catch.
An unexpected exception has been detected in native code outside the VM.
Unexpected Signal : EXCEPTION_ACCESS_VIOLATION occurred at PC=0x6d043c7a
Function name=Java_sun_java2d_loops_DefaultComponent_IntIsomorphicCopy
Library=D:\jdk1.3.1_01\jre\bin\awt.dll"
But I really don't know where it is and how to avoid it. Please help.
William

Similar Messages

  • Running two programs on one screen

    Hi,
    is there a possibility to run two different programs on one screen, independantly from each other. Or is this a kind of Container in which you can run a program?

    You might find the methods of class CL_GUI_TIMER of interest e.g. you could kick of pair of timers and have different logic run after each returns.  Is that the sort of effect you want?
    Jonathan

  • Does anybody know how to run two independent instances of Calendar simultaneously?

    I've enabled the Debug mode, and have 2 windows open at the same time but can't get them to operate independently. Anybody done this?
    The situation is that I work for a music school that uses iCal to keep track of music lessons for multiple tutors in real time, which sync to relevant tutor's iphones. We've just opened a second premises and would like to use the same system, but be able to monitor everything from either school.
    Debug mode will let me run two instances of Calendar simultaneously, but removing tutors' calendars from one of the Calendar windows removes them from the other.
    Basically I need one Calendar window open for each school, and for them to be independent from each other.
    Any takers?

    How about creating a new "Calendar" with in the same Calendar app?
    Calendar App---> File---> New Calendar
    Name each Calendar for each business location. Example if the original location is on Main St, name that Calendar Main St and the second on Broadway, name that calendar Broadway.
    The other solution could be the same as above, but File---> New Calendar subscription. But I have no idea how that works though.
    KOT

  • Running two programs using two screens

    Hi, I have a 13” Mac Book Pro OSX 10.6.7 (2010) 2.26GHz 4GB I would like to work two programs using a second screen ie iTUNES on one screen and sound editing on the second. My second monitor is a 19” Toshiba HDTV that I can connect via the Mini display port to the HDMI on the monitor, is it possible for a third application by splitting one screen into 2. THXS

    TXTJ wrote:
    Hi, I have a 13” Mac Book Pro OSX 10.6.7 (2010) 2.26GHz 4GB I would like to work two programs using a second screen ie iTUNES on one screen and sound editing on the second. My second monitor is a 19” Toshiba HDTV that I can connect via the Mini display port to the HDMI on the monitor, is it possible for a third application by splitting one screen into 2. THXS
    I don't know about a TV used as a monitor but when using a monitor as a second monitor you can do what you want. You set up the display in extended mode. Start one of your applications and drag it over to the second monitor. Start your other application and don't drag it to the second monitor. You then have an application running on each monitor.

  • How to run two programs with one PC and two monitors

    Good Morning,
    I have a requirement to run a parallel loop and update the progress in two monitors with one computer.
    For ex: its a two test stage, the process and progress of the 1st stage needs to displayed in monitor1 and similarly for 2nd stage to monitor 2 with program running with one computer.Would it be possible to do that.
    Thanks in advance

    Hi Parker,
    yes, it's possible. You also have properties to set windows to specific monitors...
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • What is the best way to run two programs simulataneously using the output from one to run the other?

    I just kind of wanted to get an opinion from some people on here. I have two main VIs. The first is a DAQ system that reads 99 different sensors and feeds that data into an array. The second is a real-time processing system that is designed to take the array and do numerous calculations. Both VIs output data to the front panel that I want to see, so I don't want to just use one as a SubVI.
    Is there a simple way to run both VIs, using the output from the DAQ system to feed the processor so that you can easily see the front panels of both VIs? I had considered just copying the real-time processor code into the DAQ VI, but I'm worried the resultant VI will be very large and unsightly.
    On a side note, am I over thinking this? Excuse me if this is a rather dumb question, it's been a long week...aaaand it's Wednesday.
    Solved!
    Go to Solution.

    There are a number of ways that you can go about this, but having both front panels open isn't a problem (assuming there is screen space!). Both could be sub-vi's of another "calling" vi, with their front panels set to open when called. The data from the DAQ side can be sent to the other through a number of ways, "producer-consumer" (many threads about this topic, examples in the LabVIEW examples, etc.) is one of the more robust techniques. If created correctly it allows one to run at a different rate than the other, although if the producer is "producing" much faster than the consumer can "consume" it will end up with problems.
    I guess I type too slowly
    Putnam
    Certified LabVIEW Developer
    Senior Test Engineer
    Currently using LV 6.1-LabVIEW 2012, RT8.5
    LabVIEW Champion

  • How to run two instances of WoW on a Mac?

    So I am looking to run two windows/instances of WoW on my mac. Basically so I can use my mage on a seperate account to rush my lowbies through instances. It wont let me simply load the game twice like on a PC, does anyone have any ideas how I could do it?

    I've never played WOW so I do not know how the settings are setup on a Mac but one way that you might be able to do it is to create a second account and try running it in both accounts. Go to System Preferences/Accounts and click on the plus to create a new account. Next click on Login Options and put a check in the box that says Enable Fast User Switching. Then from your Finder in the top right hand corner you will be able to switch between your 2 accounts.

  • Running two instances of Dreamweaver CS6

    I use Dreamweaver CS6 to build and manage a site with 10 linked sub sites. It was a first cut, and I need to rebuild it from the bottom up. Is there way to run two separate instances of Dreamweaver CS6. so I rebuild my site without running the risk of screwing up my production site?  As it sits now I have 10 production sites, 10 development/local sites and I would rather not develop the new site/s on my production instance of Dreamweaver.
    Thanks
    Russ

    It looks like on the mac I can create a new user and run a clean instance of Dreamweaver CS6.  This way if I make a stupid mistake, I do not corrupt my production site. Since my production site as 11 sub sites and another copy of the 11 sites for local development, adding the re-write to that mess would have been difficult.
    Since the projects are under different users, it is much more difficult to cross pollute the two separate projects.
    If I was doing this professionally, I would have a user account for each customer so my viagra pages did not show up on the nun web site or something like that. If I run into any issues, I will update.

  • Can Labview 5.1 Run 2 programs?

    I inherited a Labview 5.1 and it is running on one computer doing measurement. How can I use this labview to write another program to run either on the same computer (while the old one can still run) or on a different computer?
    Thanks in advance for your help.
    Kevin

    LabVIEW 5.1 has no problem running more than one VI (program) simultaneously. You can either just start the second VI by hand independently from the first, or make a new top-level VI that launches both at once, maybe using VI Server functions.
    One point to watch for is if you want to re-use subVI's (other than the built-in function blocks) that are used by the first program: if both programs need to run a subVI simultaneously you will need to make the subVI re-entrant, or make a second copy of it with a new name, otherwise one program will have to wait until the subVI call has finished in the other program. Read the help on re-entrant execution for more details.
    If you want to run two programs on different computers, you'll either need to buy another copy of LabVI
    EW or use the Application Builder to make one program into a stand-alone executable that can run without the development system. You may or may not have Application Builder already, depending on which LabVIEW package you have. See if there is a 'Build Application' entry in the Project menu. If not, ask your NI rep about your upgrade options.

  • How do run two instances of a LabView program

    Hi,
    I have a LabView application that is used for RS-485 diagnostics with a 2-port PCMCIA card in a laptop.  The application is written to access only one of these ports at a time, although the user interface does allow the user to choose which one.  What I need to do is to run two instantiations of this application, accessing one port per application, yet keeping them completely independent.  How do I do this?
    So far, I have complied an executable application, but they don't seem to be independent.  Could it be that opening one port interferes with the other.  Also, renaming the app doesn't seem to work.  It does seem clear that I have to run a compiled application because I can't run the same VI with the same subVI's independently within LabView.
    Thanks,
    Jason

    Jason,
    Here are a couple of things to think about:
    To run within the LabVIEW environment you could make the subVIs reentrant. This creates a separate data space for each instance of the VI. It does, however, mean that you cannot use the subVI's front panel.
    The built executables share the LV run time engine so there may be resource contention when you try to open the second port.
    I think you should be able to write a program in LV using VIs without reentrancy that will do what you want. Try a simple program which opens Port 1 and then Port 2 using the standard communications VIs (VISA?) and checks for errors. Multiple port stuff is done all the time. Unless the PCMCIA card does not support it. If this works then you could put together a program which monitors both ports as a single port and the port number is a parameter.
    Lynn

  • I am trying to install an update of Microsoft office and I get a message that says.  This application must be closed ETC.....   I am running Parralell and I think it is there.  The two programs are "Microsoft Database Daemon" "SyncServicesAgent"....

    I am trying to install an update of Microsoft office and I get a message that says.  This application must be closed ETC.....   I am running Parralell and I think it is there.  The two programs are "Microsoft Database Daemon" "SyncServicesAgent".  How do I close these programs?

    If the Office updates have to be run through Win in Parallels, there's not really a section here that covers that , because Neither Office or Parallels are Apple products. There is only a small chance that you'll find someone with BOTH your conditions who just happend to look into a forum on older iMacs.
    Parallels has a forum here:
    http://forum.parallels.com/forum.php
    I think you'll get a faster response there.

  • Can I run two instances of mail at the same time?

    To avoid accidentally sending an email from the wrong account, I want to use an email program (that can access an Exchange account) "dedicated" to just that account. To do this, I think have to use either Mail or Outlook. I don't have Outlook, and use Mail for my other accounts.
    So, can I duplicate the Mail program (on another of the internal drives if that would help) and use it exclusively for this one account or would it screw everything up?

    In that case the only other way I know you can do it is to set up an alternative user account on the mac, which will give you two separate instances of Mail (the one you already have and a new one in the new user account).
    To do that, go here
     > System Preferences... > Users & Groups
    and create a new user by first clicking the padlock at the bottom, entering your password, and then clicking the '+' button just above the padlock. Fill out the account details and enable 'fast switching' in the options so you can easily switch between the two mac user accounts.
    Log in to the new user's account and create the work email account in Mail.

  • How can I run two instances of Firefox: one in Safe Mode and another in Normal Mode?

    I think my question says it all.

    You can't simultaneously run a normal instance and a Safe Mode instance using the same profile. So step one is to create a new profile.
    * [[Use the Profile Manager to create and remove Firefox profiles]]
    Right-click the desktop and choose New, then Shortcut. As the location of the item, use the following, substituting the placeholder profile name with the actual profile name you chose earlier.
    "C:\Program Files (x86)\Mozilla Firefox\firefox.exe" -no-remote -p NameOfTheProfile
    * https://developer.mozilla.org/docs/Mozilla/Command_Line_Options

  • How to check if ABAP program is running in another instance?

    Hey Guys,
    I need to ensure that a given ABAP program is only running in one instance.
    Here is what I tried so far:
    1) FM TH_WPINFO
    The problem with this is that the Z (custom) program calls lot of SAP function modules and when inside those, the WP_REPORT field of WPLIST table has something else and not the Z program name.
    2) FM ENQUEUE_ESINDX
    When I used the code below the following happened:
    -The First instance runs fine
    -The Second instance fails in the locking and exits the way it is supposed to but then
    -If I run the program the Third time, it runs with a succesful lock - probably because the after second instance the lock was cleared???
    CALL FUNCTION 'ENQUEUE_ESINDX'
        EXPORTING
         MODE_INDX            = 'E'
         MANDT                = SY-MANDT
         RELID                = 'ZZ'
         SRTFD                = PROGRAM
    *     SRTF2                =
    *     X_RELID              = ' '
    *     X_SRTFD              = ' '
    *     X_SRTF2              = ' '
    *     _SCOPE               = '2'
    *     _WAIT                = ' '
    *     _COLLECT             = ' '
        EXCEPTIONS
          FOREIGN_LOCK         = 1
          SYSTEM_FAILURE       = 2
          OTHERS               = 3.
    Any other idea, how I could accomplish this?
    Thanks a lot,
    Viktor

    -----> Include this perform in Initalization or in Start-of-Selection screen event.
    *&      Form  LOCK_CURRENT_INSTANCE
    * Perform to lock the current instance of the
    * program, so that only one
    * instance can be runned at a given time.
    FORM lock_current_instance .
    *---FM to lock the current instance of the program
        CALL FUNCTION 'ENQUEUE_E_TRDIR'
          EXPORTING
            mode_trdir     = abap_true
            name           = sy-repid
          EXCEPTIONS
            foreign_lock   = 1
            system_failure = 2
            OTHERS         = 3.
        IF sy-subrc <> 0.
          IF sy-batch = abap_true.
            MESSAGE e016 WITH 'Already one Instance of the Program is Running'.
          ELSE.
            MESSAGE s016 WITH 'Already one Instance of the Program is Running' DISPLAY LIKE 'E' .
            LEAVE LIST-PROCESSING.
          ENDIF.
        ENDIF.
    ENDFORM.                    " LOCK_CURRENT_INSTANCE
    ---->and include this perform as a last perform in End-of-Selection screen event.
    *&      Form  UNLOCK_CURRENT_INSTANCE
    * This perform is used to unlock the instance of the
    * running program
    FORM unlock_current_instance .
    *---FM to release the lock on the running program
      CALL FUNCTION 'DEQUEUE_E_TRDIR'
        EXPORTING
          mode_trdir = abap_true
          name       = sy-repid.
    ENDFORM.                    " UNLOCK_CURRENT_INSTANCE

  • Two operating systems in one computer - Running a program

    Hi.
    I have just installed two operating systems in my Thinkpad: windows 8 and windows 7. Is that possible to run a program, say Photoshop, MS Office, installed in windows 8 OS while I am running windows 7? I do not want to reinstall all the programs in windows 8 when using windows 7 because they are still in the same computer.
    I tried to clicked on a program (from W8 Program x86). It asks for serial keys. I entered but it said that i do not have sufficient priviledge???
    One more question:
    I have an external hard drive. Is that possible when I install a program on that external hard drive, instead of internal hard drive, and run from that external hard drive? I mean: I install a program on external hard drive, then run that program in external HD from other computer?
    I hope to have your insight solutions for this problem.
    Thank you
    Solved!
    Go to Solution.

    Basically all more advanced programs cannot be run this way. They utilize registry entries, app data, environment variables etc. hence are tied to the OS they are installed on. 
    Some simple applications, which don't require to be installed or have a portable version will work. This list does not include Office or Photoshop.
    The answer for the external hard drive is the same. You'll need a "portable" application, which doesn't store any OS or user specific information.
    You can look here http://portableapps.com/ for applications that are not tied to an OS.

Maybe you are looking for