Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
1.3 KiB

  1. On Error Resume Next
  2. Dim hr
  3. Dim fModem
  4. Dim lBandwidth
  5. Dim fOnline
  6. Dim pmpcConnection
  7. Stop
  8. Set pmpcConnection = WScript.CreateObject("UploadManager.MPCConnection")
  9. hr = Err.Number
  10. if (hr <> 0) then
  11. WScript.Echo "Err Number: " & Err.Number
  12. WScript.Echo "Err Desc : " & Err.Description
  13. WScript.Echo "Err Source: " & Err.Source
  14. WScript.Quit hr
  15. end if
  16. fOnline = pmpcConnection.Available
  17. hr = Err.Number
  18. if (hr <> 0) then
  19. WScript.Echo "Err Number: " & Err.Number
  20. WScript.Echo "Err Desc : " & Err.Description
  21. WScript.Echo "Err Source: " & Err.Source
  22. WScript.Quit hr
  23. end if
  24. fModem = pmpcConnection.IsAModem
  25. hr = Err.Number
  26. if (hr <> 0) then
  27. WScript.Echo "Err Number: " & Err.Number
  28. WScript.Echo "Err Desc : " & Err.Description
  29. WScript.Echo "Err Source: " & Err.Source
  30. WScript.Quit hr
  31. end if
  32. lBandwidth = pmpcConnection.Bandwidth
  33. hr = Err.Number
  34. if (hr <> 0) then
  35. WScript.Echo "Err Number: " & Err.Number
  36. WScript.Echo "Err Desc : " & Err.Description
  37. WScript.Echo "Err Source: " & Err.Source
  38. WScript.Quit hr
  39. end if
  40. WScript.Echo "Connection Status:"
  41. WScript.Echo
  42. WScript.Echo " fModem: " & fModem
  43. WScript.Echo " dwBandwidth: " & lBandwidth
  44. WScript.Echo " fOnline: " & fOnline
  45. WScript.Echo
  46. Set pmpcConnection = Nothing