|
-
Jan 9th, 2001, 04:14 PM
#1
Thread Starter
New Member
Can someone please help me? I am trying to read the registry on Windows NT Server 4.0 using VBScript. I would rather not have to use API calls unless it is absolutely necessary. I am trying to get the machines 'computer name' under the identification tab of the Network Neighborhood Properties. I have it located in the registry, but it seems that my scripts do not work properly. Please help...
[email protected]
thanks
-
Jan 10th, 2001, 12:46 AM
#2
Guru
You can't directly read from the registry thru VBScript/ASP, you'll need a component to do that for you
fortunately, you can use the Scripting Object Model to do this for you, and I have whipped up some ASP code to show you how
Code:
<%@Language=VBScript EnableSessionState=False%>
<% option explicit %>
<html>
<body>
<%
Dim objNetwork
Set objNetwork = Server.CreateObject("WScript.Network")
Response.Write "Computer Name: " & objNetwork.ComputerName
Set objNetwork = Nothing
%>
</body>
</html>
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|