Results 1 to 4 of 4

Thread: [RESOLVED] VB6: How to check whether a PC of my workgroup are on or off?

  1. #1

    Thread Starter
    Member
    Join Date
    Jun 2010
    Posts
    40

    Resolved [RESOLVED] VB6: How to check whether a PC of my workgroup are on or off?

    In my Windows' workgroup I have several PC. I can access them via:
    \\PC1
    \\PC2\documents
    \\PC3
    etc

    Now, how can I check if they're on or off?
    I came up with this:

    Code:
            On Error GoTo IsOff
            Open "\\PC2\test.txt" For Output As 5:close
            Msgbox "It's ON"
            exit sub
    
    IsOff:
           MsgBox "It's OFF"

    but every time I do that, the program freezes like 5 seconds if PC is off. Can I reduce that time of waiting or try something else?

  2. #2

  3. #3

    Thread Starter
    Member
    Join Date
    Jun 2010
    Posts
    40

    Re: VB6: How to check whether a PC of my workgroup are on or off?

    Quote Originally Posted by RhinoBull View Post
    Try out this sample.
    Thanks, RinoBull!
    Worked out perfectly

  4. #4

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width