%@ LANGUAGE="VBSCRIPT"%>
Scripting Test 1
<%
on error resume next
Set Locator = CreateObject("WbemScripting.SWbemLocator")
Set Service = locator.connectserver ("ludlow")
if Err = 0 then
Set Disk = Service.Get ("Win32_LogicalDisk")
Set Path = Disk.Path_
Disk.Security_.impersonationLevel = 3
Set Disks = Disk.Instances_
%>
Path of object is <%=Path.DisplayName%>
Name |
Volume Name |
Volume Serial Number |
<%
for each DiskInstance in Disks
%>
<%=DiskInstance.Name%> |
<%=DiskInstance.VolumeName%> |
<%=DiskInstance.VolumeSerialNumber%> |
<%
Next
%>
<%
Else
%>
Error - <%=Err.description%>, <%=Err.number%>, <%=Err.Source%>
<%
end if
%>