944,166 Members | Top Members by Rank

Ad:
Jan 12th, 2007
0

Single instance

Expand Post »
Does anyone know how to do single instance in VB.. Pls help me...
Reputation Points: 10
Solved Threads: 0
Newbie Poster
yuni is offline Offline
1 posts
since Jan 2007
Jan 12th, 2007
0

Re: Single instance

What exactly are you asking? Please describe the problem better.
Reputation Points: 45
Solved Threads: 28
Posting Whiz in Training
Dukane is offline Offline
282 posts
since Oct 2006
Jan 12th, 2007
0

Re: Single instance

I don't think there is any one specific way to limit a program to a single instance. Some use a registry entry to determine if there is an instance already running, while others use a file or create a system-wide semaphore (see MSDN for CreateSemaphore() win32 api function)
Sponsor
Team Colleague
Featured Poster
Reputation Points: 5608
Solved Threads: 2283
Retired and Enjoying Life
Ancient Dragon is offline Offline
21,963 posts
since Aug 2005
Jan 12th, 2007
0

Re: Single instance

> Does anyone know how to do single instance in VB.. Pls help me...

Are you talking about creating class instances in a VB program... ?
Super Moderator
Featured Poster
Reputation Points: 3241
Solved Threads: 719
Failure as a human
~s.o.s~ is offline Offline
8,873 posts
since Jun 2006
Jan 13th, 2007
0

Re: Single instance

Hi,

Use this Code :
In ur MDIFormLoad Or the StartUp Form Load.

Private Sub MYMDIForm_Load()
    If App.PrevInstance Then
        End
    End If
End Sub
Reputation Points: 84
Solved Threads: 140
Posting Shark
QVeen72 is offline Offline
923 posts
since Nov 2006

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Visual Basic 4 / 5 / 6 Forum Timeline: how can i find "Software Version" using VB6?
Next Thread in Visual Basic 4 / 5 / 6 Forum Timeline: Error 424-object required





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC