Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. creating a timeout

creating a timeout

Scheduled Pinned Locked Moved C / C++ / MFC
c++sysadmin
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    viperlogic
    wrote on last edited by
    #1

    I have a Visual C++6 project for extracting WMI information from machines across the network. I am using the IWbemLocator::ConnectServer method with the WBEM_FLAG_CONNECT_USE_MAX_WAIT flag. The flag prevents the app from hanging and will timeout the call if not sucuessful after 2mins. But this flag only works for XP pcs and no other like 2000 etc and also is fixed at 2mins. how can a timeout be implemented so i can kill the ConnectServer method say after 20seconds.

    R 1 Reply Last reply
    0
    • V viperlogic

      I have a Visual C++6 project for extracting WMI information from machines across the network. I am using the IWbemLocator::ConnectServer method with the WBEM_FLAG_CONNECT_USE_MAX_WAIT flag. The flag prevents the app from hanging and will timeout the call if not sucuessful after 2mins. But this flag only works for XP pcs and no other like 2000 etc and also is fixed at 2mins. how can a timeout be implemented so i can kill the ConnectServer method say after 20seconds.

      R Offline
      R Offline
      Ray Kinsella
      wrote on last edited by
      #2

      Hi, This is kind of thing I would use another thread for ... Regards Ray "Je Suis Mort De Rire" Blogging @ Keratoconus Watch

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups