Click here to Skip to main content
15,886,919 members
Home / Discussions / C#
   

C#

 
GeneralRe: Starting a process on a remote machine with WMI Pin
scadaguy9-Feb-04 10:49
scadaguy9-Feb-04 10:49 
GeneralLinklabel Pin
c5328699-Feb-04 7:47
c5328699-Feb-04 7:47 
GeneralRe: Linklabel Pin
Mike Ellison9-Feb-04 8:19
Mike Ellison9-Feb-04 8:19 
GeneralRe: Linklabel Pin
Charlie Williams9-Feb-04 9:08
Charlie Williams9-Feb-04 9:08 
GeneralRe: Linklabel Pin
Charlie Williams9-Feb-04 9:03
Charlie Williams9-Feb-04 9:03 
GeneralRe: Linklabel Pin
Anonymous9-Feb-04 14:41
Anonymous9-Feb-04 14:41 
QuestionHow can I detect when a client disconnects from a well known service? Pin
Marc Clifton9-Feb-04 6:13
mvaMarc Clifton9-Feb-04 6:13 
AnswerRe: How can I detect when a client disconnects from a well known service? Pin
LongRange.Shooter9-Feb-04 8:17
LongRange.Shooter9-Feb-04 8:17 
You may not like this answer....I had a situation where I had users from all over the country connecting to a remote object. I had the need to do two things: show everyone who is using the server -and- b) know when one of the users lost their connection.

My approach was to deploy a global object. It is a Singleton. It holds an array of those connected to the server and has a 6 hour lifetimeservice. This helps to assure I do not lose my name list while users are on but inactive.

I have each client connect to the global object and execute PublishIdentity("name");

I then have two threads running:
thread a) on client sends pings (NotifyGlobal("name")) to the global object every 15 minutes telling it the client is alive.
thread b) on server checks lists for users who did not respond in more than 30 minutes. Those are purged from the list.

When there is nothing in the list and my time expires I am purged. I use that to indicate I have to shut down my thread in the destructor. You could use the zero count to indicate when to clear your objects.



_____________________________________________
Of all the senses I could possibly lose,
It is most often the one called 'common' that gets lost.

GeneralRe: How can I detect when a client disconnects from a well known service? Pin
Marc Clifton9-Feb-04 8:21
mvaMarc Clifton9-Feb-04 8:21 
GeneralRe: How can I detect when a client disconnects from a well known service? Pin
LongRange.Shooter9-Feb-04 8:26
LongRange.Shooter9-Feb-04 8:26 
AnswerRe: How can I detect when a client disconnects from a well known service? Pin
Tom Larsen9-Feb-04 10:30
Tom Larsen9-Feb-04 10:30 
GeneralRe: How can I detect when a client disconnects from a well known service? Pin
Marc Clifton9-Feb-04 10:58
mvaMarc Clifton9-Feb-04 10:58 
GeneralRe: How can I detect when a client disconnects from a well known service? Pin
Tom Larsen9-Feb-04 11:37
Tom Larsen9-Feb-04 11:37 
GeneralRe: How can I detect when a client disconnects from a well known service? Pin
Marc Clifton9-Feb-04 13:30
mvaMarc Clifton9-Feb-04 13:30 
GeneralRe: How can I detect when a client disconnects from a well known service? Pin
Tom Larsen10-Feb-04 7:04
Tom Larsen10-Feb-04 7:04 
GeneralRe: How can I detect when a client disconnects from a well known service? Pin
LongRange.Shooter10-Feb-04 9:08
LongRange.Shooter10-Feb-04 9:08 
GeneralRe: How can I detect when a client disconnects from a well known service? Pin
Tom Larsen11-Feb-04 3:53
Tom Larsen11-Feb-04 3:53 
GeneralRe: How can I detect when a client disconnects from a well known service? Pin
HAHAHA_NEXT9-Feb-04 11:01
HAHAHA_NEXT9-Feb-04 11:01 
QuestionHow to get/set printer paper media type Pin
trythat9-Feb-04 5:55
trythat9-Feb-04 5:55 
QuestionDynamic attributes for propertyGrid??? Pin
LongRange.Shooter9-Feb-04 3:11
LongRange.Shooter9-Feb-04 3:11 
AnswerRe: Dynamic attributes for propertyGrid??? Pin
Heath Stewart9-Feb-04 4:17
protectorHeath Stewart9-Feb-04 4:17 
GeneralRe: Dynamic attributes for propertyGrid??? Pin
LongRange.Shooter9-Feb-04 8:09
LongRange.Shooter9-Feb-04 8:09 
GeneralRe: Dynamic attributes for propertyGrid??? Pin
Heath Stewart9-Feb-04 9:33
protectorHeath Stewart9-Feb-04 9:33 
GeneralRe: Dynamic attributes for propertyGrid??? Pin
LongRange.Shooter9-Feb-04 10:38
LongRange.Shooter9-Feb-04 10:38 
GeneralRe: Dynamic attributes for propertyGrid??? Pin
Heath Stewart9-Feb-04 14:02
protectorHeath Stewart9-Feb-04 14:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.