How to stop a class which don't use thread is running

i have a class call my.class, in my application, i use a button "start button" to run this class by call: my.main(new String[0])
now I want to use another button call "stop button" to stop my.class.
If in my.class I don't use thread, have any way to stop it
please help me, it verry importand for me
Any help will hightly wellcomed

I take it that TimTheEnchanters reply to this question was scrubbed by your browser?
http://forum.java.sun.com/thread.jspa?threadID=579074&tstart=30

Similar Messages

  • I have my personal music (not purchased from Itunes) stored in two locations, on my PC and on an external HD. How can I find out which directory itunes uses to access this music? I am using Itunes version 11.4.0.18. Thanks

    I have my personal music (not purchased from Itunes) stored in two locations, on my PC and on an external HD. How can I find out which directory itunes uses to access this music? I am using Itunes version 11.4.0.18. Thanks

    Many thanks JEM24 for your help.  Ive just spent the best part of six hundred pounds on a new Sony Rx100m2 compact camera, so I have no interest in the Ipods camera at all really. I doubt Ill be watching many videos on it as Im very lucky in that I have a good Android tablet. Its more as a stock music player that Ill be buying the Ipod for, if indeed I do end up buying one. I dont like the idea of paying the exorbitant amount added for more memory space that Apple along with most other companies charge. In fact I read an article on this very subject just yesterday in the tech section of Flipboard. It stated in the article that in the case of the Iphone  the actual cost of each additional  gigabyte of storage  to Apple et al is something in the order of 60p.. This is certainly not reflected in the price us the customer has to pay at the till.. Its for this reason primarily that Apple in particular, because their products do not allow adding expandable memory of your own in the form of cheap to buy cards, that nobody in their right mind buys the 64gig etc Iphones..I am aware that we are discussing my potential purchase of an Ipod Touch here but you see my point. Many thanks again though for helping me.

  • How do I find out which instruments are used by software instrument loops?

    This isn't so much a problem, it's just something that's been bugging me - how do I find out which instruments are used by the software instrument loops?
    Usually clicking on a track will bring up the instrument name in the track info pane, but if I do this after importing a software instrument loop into my song it doesn't show anything. Any ideas?
    PS I have used the search function so I apologise in advance if there's an obvious answer.

    in track info, under details, the instrument being used is displayed in the generator popUp menu

  • How to deal with the mouse events when the thread is running

    Hi everybody,
    I have a problem with my program.
    Now I want to present a picture for some time in the Canvas,then automatically clear the screen, but when the user press the mousebutton or keybutton, I want to stop the thread and clear the screen.
    How can I receive the mouse event when the thread is running?
    Thanks,

    I use my code in a GUI applet.
    I try to use the code tag, it's the first time.
                   Image im=sd.getStimulus(obj);
                   if(pos==null){
                        g.drawImage(im, (w-im.getWidth(null))/2,(h-im.getHeight(null))/2,null);
                   }else{
                        g.drawImage(im, pos.x,pos.y,pos.w,pos.h,null);
                   try{
                        sleep(showtime);
    //                    Thread.sleep(showtime);
                   }catch(InterruptedException e){}
                   if(pos==null){
                        g.clearRect((w-im.getWidth(null))/2,(h-im.getHeight(null))/2,im.getWidth(null),im.getHeight(null));
                   }else{
                        g.clearRect(pos.x,pos.y, pos.w, pos.h);
                   }

  • How to load a class , which isn't in the classpath environment variable.

    Hi, you folks.
    I have one problem. I want to load a class, which isn't in the classpath
    environment variable and I don't want to put into classpath. which method
    JVM can use to load it?
    Waitting for your sage advice.
    Regareds
    Hunter.Xiao

    You will have to write your own ClassLoader, or use something like URLClassLoader (I've never used this myself, but I've seen it mentioned elsewhere in this forum). Look here.

  • How to stop the rotation i don't want to happenin relationship in mountain lion

    how do i stop the rotation i don't want to happening relationship in mountain lion. Everytime I try and work now, the page swipe deal happens, I hate that on my Mac, and then my page all the sudden rotates and I can't figure out how to stop that from happeneing and even make it go back. Happens in photoshop, indesign, etc. help.

    nevermind. I found the answer in another place. I have now disabled the gestures. I get gestures for ipads and ipods, but not my regular work mac. Irritating. But got it now and my documnet is back to normal.

  • HT204053 how can i find out which id i used to purchase an app?

    i can't update iphoto, imovie and garageband cause it says "sign in to the account you used to purchase it" but those were pre-installed when i bought my iMac and i don't have a second id. what can i do or how can i find out which is the right account for these apps?
    thanks in advance

    I also have a linked problem like that. I bought various apps under different ids and now I don't know how to sign in - where to sign in under the emails that I bought them on so i can't update my Pages app.
    Can anyone help us please?
    Is there a way to put them altogether now under my apple id with icloud?
    Thanks

  • How to create a material which can be used in T-Codes VAO1 & MB1C create

    Hello Experts,
    How can I create a material which can be used to create a sales order and can be used to create inventory using VAO1 and MB1C T-Codes respectively.
    What are the configurations that I need to take care of, while creating it?
    I need to create a material which can be used in the whole sales cycle(sales order,goods issue,billing and etc).
    Please Help,
    Thanks in Advance,
    Suma

    Hi
    Thanks for your fast replies.. I have created a new material and was able to create inventory thru MB1C. But I was not able to generate a goods delivery(VL01N) and billing document(VF01)  for the sales order.
    Error: No schedule lines due for delivery up to the selected date
    Message no. VL248
    Diagnosis
    There are no schedule lines due for the given order item up to the date chosen.
    System Response
    The system does not create a delivery item for this order item.
    Procedure
    Check whether the order item to be delivered contains confirmed schedule lines.
    If this is the case, set the selection date further into the future if you still want to create a delivery for this item.
    Please suggest,
    Tanks,
    Suma
    Edited by: Suma B on Sep 23, 2008 3:55 PM

  • How to stop reuse asset code once its use in po

    Dear All,
    how to stop reuse of asset code once its use in PO or PR.
    Thanks & Regards,
    Mukesh Chejara
    SAP

    Dear All,
    Awaiting your valuable reply.
    Thanks & Regards,
    Mukesh Chejara
    SAP

  • Interface/class which can be used for obtaining exchange rates of currency

    Is there any interface or class in the java package which can be used for obtaining current exchange rates of currencies ?

    Yes. The people at Sun change the static fields every day to reflect the current prices on the world currency markets at GMT 12:00. Then every day all the java programmers around the world reinstall a new JDK that contains the updated class. The class is called:
    EuroDollarDollarEuroDollarYenYenDollarYenEuroEuroYenRubleDollarDollarRuble
    To access the Euro-Dollar exchange rate, you write:
    EuroDollarDollarEuroDollarYenYenDollarYenEuroEuroYenRubleDollarDollarRuble.EURODOLLAR

  • Mainstage - how to "hold" a note - which CC is used?

    Hi all,
    I'd like to be able to hold a note(s) indefinitely using a momentary switch on my midi footcontroller.  I tried using CC 64 but that only sustains and drops off as you know.  I'd like a complete hold (same velocity, volume, etc) which CC is used for Hold if any?  Or is it dependent on the software instrument?
    Thanks!
    Jas

    Thanks for responding...yeah, just to give you a bit more background I'm using a MIDI guitar going into an Axon pitch to MIDI converter, Axon->RME UC, then the MIDI messages (note, etc) come in to MS via USB from the UC. 
    I then use a software instrument (synth, etc) and I want to be able to hold a note(s) when playing in order to then play over using another instrument.  My plan is to use my Gordius MIDI footcontroller to send a "hold" CC via a momentary switch into MS to trigger the hold then let up when done but I don't know what the CC is to do that or if that functionality even exists (but can't see why it wouldn't).
    There may be another way I'm not thinking about.
    Thanks,
    J.

  • How to create a timer function by only using Threads

    I have used Timer & Timer Task but since they r only available for JDK1.3 and i need this to work on 1.2 also can any one tell me if i can create the same function using Threads.

    i had to do the same (heres roughly what i used...)
    interface TimerTask{
    public void timeout();
    class Timer extends Thread{
    private int delay;
    private TimerTask user;
    Timer(int delay,TimerTask user){
      this.delay=delay;
      this.user=user;
    public void run(){
      try{
       Thread.sleep(delay);            //*
      catch(InteruptedException IE){};
      user.timeout();                  //*
    }as you can see, very rough, but the basics
    refinements could be to add some flags to alter its behaviour..
    like, a loop if you want recuring events
    the commented lines might be rearranged if you dont want it to generate an event just because there is some shut down going on
    as it is an instance of a class could only use 1 Timer, to change this TimerTask.timeout() could be changed to TimerTask.timeout(Timer) so you could determine which Timer had triggered

  • How to import a class, which is not in a package?

    Hi all,
    I have the following problem:
    A class A is not in a package. In another class B, which is in a package (let's say package X) I want to use the class A. Without importing the class A, I get the error "Cannot resolve symbol".
    Using the import statement import A; gives the error ". expected".
    How can I import that class?
    Best wishes to all ...
    Heiko

    > I have the following problem:
    A class A is not in a package. In another class B,
    which is in a package (let's say package X) I want to
    use the class A. Without importing the class A, I get
    the error "Cannot resolve symbol".
    I think not putting a class in a package is a bad practice. Avoid that.

  • How to stop the job which is running infinite time......

    Hi ,
    I created one procedure with the below code. Using dbms_scheduler i created one job and called that program. That job is in sleep mode for long time. How can i stop that job.
    create or replace procedure bpc_test_batch
    is
    begin
    dbms_lock(30000000)
    end;
    Regards,
    Thiru

    Have you tried this already?
    exec dbms_scheduler.stop_job('Your_Job_Name',true);

  • How to stop the TR which has run a long time

    Hi,
    I released a TR, but the system import it a long time. I think maybe have a problem with it.
    I want to stop the import job of the TR. How can I do for that?
    jk

    hi,
    Q: How to kill a long running job in SAP.
    Answer
    You can 'kill' your own long running jobs by doing the following.
    Open a new SAP session.
    In the new session, from the SAP R/3 screen, follow the menu path: Tools>>Administration
    (new screen) Monitoring >>System monitoring>>User overview
    Fastpath:  /nsm04
    Result: the "Overview of Users" screen appears. This is a list of the jobs currently running.
    Find your username in the list and click on it
    Click on the Sessions button .
    Result: the Overview of Sessions screen appears.
    Click on the End session button .
    hi, ask your BASIS people for killing the job..
    regards
    vijay

Maybe you are looking for

  • Payment terms for advance payment scenario

    Dear All payment terms have to create like we have to pay as 50% advance against order & balance 50% against on proforma invoice. Can any one tell me is it possible to define payment terms like this or only option is downpayment configuration. Thanks

  • How do I downgrade Java 8 to Java 7 Mac 10.9.1

    I was going to play a game that requires Java, but it claims my Java version is outdated, so I can either choose to 'update', 'block' or 'later'. At first I tried 'update' and download Java 7, which is the latest on the website. When I opened the pkg

  • Help with fonts...

    Hi - I'm totally new at this, so please be gentle! I'm trying to build my first website in dreamweaver cs5 and having trouble with some fonts - namely the helvetica neue suite... which came installed on my mac (dfont). I'm not sure if I've done this

  • Identifying form fields automatically when word doc is imported

    Hi I am trying to convert a word document template to a PDF template using Adobe Live Cycle. There are 7 tables in the Word document. I saved the doc as PDF using Word. When i imported the PDF into the Live Cycle Designer, the form fields ( table row

  • Request for code window

    It would be nice to have the label names from the timeline in the code panel even though Edge uses time.