Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8022031
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T22:09:29+00:00 2026-06-04T22:09:29+00:00

I need to test the response time from a web url to see if

  • 0

I need to test the response time from a web url to see if it’s getting a slow response. I have this from a tutorial website (can’t remember which) but it doesn’t do exactly what I want:

On Error Resume Next 
Set XMLHttp = CreateObject("MSXML2.ServerXMLHTTP") 
xmlhttp.open "GET", "http://website.url.com" , 0 
xmlhttp.send "" 
If Err.Number < 0 OR Err.Number > 0 Then 
  Dim objShell
  Set objShell = WScript.CreateObject ("WScript.shell")
  MsgBox "TimeOut"
  Set objShell = Nothing
  WScript.Quit 
Else
  MsgBox "OK"
End If 

Set xmlhttp = Nothing

This script only tests if the site timesout or not. I would need more detailed information such as even if it doesn’t time out, how long was the response time, etc.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T22:09:31+00:00Added an answer on June 4, 2026 at 10:09 pm

    OK, I found the solution:

    Dim strHost
    
    ' Put your server here
    strHost = "localhost"
    
    if Ping(strHost) = True then
        Wscript.Echo "Host " & strHost & " contacted"
    Else
        Wscript.Echo "Host " & strHost & " could not be contacted"
    end if
    
    Function Ping(strHost)
    
        dim objPing, objRetStatus
    
        set objPing = GetObject("winmgmts:{impersonationLevel=impersonate}").ExecQuery _
          ("select * from Win32_PingStatus where address = '" & strHost & "'")
    
        for each objRetStatus in objPing
            if IsNull(objRetStatus.StatusCode) or objRetStatus.StatusCode<>0 then
            Ping = False
                'WScript.Echo "Status code is " & objRetStatus.StatusCode
            else
                Ping = True
                'Wscript.Echo "Bytes = " & vbTab & objRetStatus.BufferSize
                Wscript.Echo "Time (ms) = " & vbTab & objRetStatus.ResponseTime
                'Wscript.Echo "TTL (s) = " & vbTab & objRetStatus.ResponseTimeToLive
            end if
        next
    End Function 
    

    All credits go to this website and it’s author: http://www.windowsitpro.com/article/vbscript/how-can-i-use-a-vbscript-script-to-ping-a-machine-

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following xml I need to read the values of: <po-response xmlns=http://test.com<
In my web application I would like to make a response-test process. This process
This is a test application: #!/usr/bin/env python from flask import Flask from time import
I need to test if a user can write to a folder before actually
I need to test my application. Its a VoIP but each time I need
I need to test the bandwidth I have on my USB RNDIS connection. I
I need to test a database user to see if that user has privileges
i get a JSON response from a web service: {CoverageSearchByLatLongResult:{HasTransmissionAreasWithSignal:true,SwitchOffArea: {OpenForVastApplications:false,SeperateTileSetUrl:http:\/\/myswitch.merged.stage.orchard.net.au\/geodatafiles\/SwitchOffArea\/442b8844-3c05-4548-9424- 4fdafc1f3c62\/Seperate,HASStatus:Future,HASStatement:<p>The Household Assistance
I have to create mutiple web request to same URL using webclient. I spawn
I have the following form and javascript function on my web page. This is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.