Allow only single instance of application to run

Last post 11-06-2009 3:04 PM by TATWORTH. 5 replies.

Sort Posts:

  • Allow only single instance of application to run

    11-02-2009, 11:51 AM
    • Member
      3 point Member
    • user2009
    • Member since 10-07-2009, 9:58 PM
    • Posts 20

    I want to allow only one instance of the application to run on a particular system. If the application is already running and if the user tries to invoke the other instance it should not. 

  • Re: Allow only single instance of application to run

    11-02-2009, 12:21 PM
    • All-Star
      25,615 point All-Star
    • qwe123kids
    • Member since 03-27-2008, 5:49 AM
    • Mumbai
    • Posts 4,381

    Hi,

    http://blogs.msdn.com/onoj/archive/2004/06/04/148532.aspx

    OR

    I Don't really rember there is Some setting In project Propety which Allow single Instance..


    Thanks
    Avinash Tiwari

    Remember to click “Mark as Answer” on the post, if it helps you.

    MY Blog

    Hacking Inside .net exe
  • Re: Allow only single instance of application to run

    11-02-2009, 2:35 PM
    • Member
      3 point Member
    • user2009
    • Member since 10-07-2009, 9:58 PM
    • Posts 20

    All of these are using the Win32 API's. Is there any way to do it without the API's 

  • Re: Allow only single instance of application to run

    11-06-2009, 2:03 PM
    • Member
      280 point Member
    • rakesh2kv
    • Member since 10-27-2008, 6:41 PM
    • Posts 240

    This should help

    http://www.ai.uga.edu/mc/SingleInstance.html

  • Re: Allow only single instance of application to run

    11-06-2009, 2:09 PM
    • All-Star
      25,615 point All-Star
    • qwe123kids
    • Member since 03-27-2008, 5:49 AM
    • Mumbai
    • Posts 4,381

    U may Also Use GetProcess()

    Use GetProcess() on Load Chk is process is there if There then Donot Allow the user to Load else allow

    http://www.java2s.com/Code/CSharp/Development-Class/GetProcessproperty.htm

    http://www.howtogeek.com/howto/programming/get-a-list-of-running-processes-in-c/

    Thanks
    Avinash Tiwari

    Remember to click “Mark as Answer” on the post, if it helps you.

    MY Blog

    Hacking Inside .net exe
  • Re: Allow only single instance of application to run

    11-06-2009, 3:04 PM
    Answer
    • All-Star
      62,829 point All-Star
    • TATWORTH
    • Member since 02-04-2003, 1:34 PM
    • England
    • Posts 12,265
    • TrustedFriends-MVPs

    This appears to be a WinForms question. If so, please ask at:

    Don't forget to click "Mark as Answer" on the post that helped you.
    This credits that member, earns you a point and marks your thread as Resolved so we will all know you have been helped.
Page 1 of 1 (6 items)