Results 1 to 1 of 1
  1. #1

    Question Get CPUusage asp code.

    Hi everyone,

    Now I am trying to find out an ASP code can get the CpuUsage of my server (win2000 server). It looks like that:

    <%
    Set CpuInfo = Server.CreateObject("CpuDll.CpuUsage")
    a = CpuInfo.CPU_Usage_Percent

    Response.Write(a)
    %>

    I used Visual Basic to compile a DLL file to run above script, I did it from this script: CS_CPU_Monitor.zip (attach file below) and run regsvr32 CpuDll.dll to register it to my server.

    But when I run above script, Response.Write(a) always returns: 100 , even at that time my server CPU is much lower than 100 percent.

    Anybody had any experience in this or had any other methods to get the cpu usage in ASP code.

    Looking forward to hearing from you

    Thanks in advance.
    Attached Files Attached Files
    Last edited by magpie; 01-08-2005 at 02:30 AM.

Posting Permissions

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