Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ActiveX error on GetObject

Status
Not open for further replies.

skispray

Programmer
Feb 28, 2003
16
US
I have an ASP.NET page that I'm trying to use to change the password of the local Administrator account on remote machines. When I run this on my workstation it works, but when I post it to the intranet server and run it I get this error:
[blue]System.Exception: Cannot create ActiveX component. at Microsoft.VisualBasic.Interaction.GetObject(String PathName, String Class)[/blue]

Here's my code
Code:
Dim strComputer = ddlServers.SelectedValue
Dim strUser = txtUser.Text
Dim objUser = GetObject("WinNT://" & strComputer & "/" & strUser & ", user")
objUser.SetPassword(txtPW1.Text)
objUser.SetInfo()

Any ideas why this won't work when posted to the server? Thanks!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top