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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Converting VB6 code to VBScript: any idea (using IMSTscNonScriptable)

Status
Not open for further replies.

aviret

Programmer
May 28, 1999
7
0
0
CH
The following code works within VB6. How could I declare (or cast) an object like "NonScriptable" in VBScript ?

Private Sub btnSejour_Click()
Dim NonScriptable As IMsTscNonScriptable

Set NonScriptable = MsTscAx1.Object
MsTscAx1.Server = "myserver"
MsTscAx1.Domain = "mydomain"
MsTscAx1.Username = "myuser"
NonScriptable.ClearTextPassword = "mypassword"
MsTscAx1.FullScreenTitle = FullScreenTitleTxt & "(MyApp)"
MsTscAx1.Connect
End Sub

Thanks in advance for your help ;-),
Greetings,
Alain
 
If the .dll is registered on the server where you want to declare the object, then all you need to do is:

Dim NonScriptable
set NonScriptable = server.createObject("IMsTscNonScriptable")

Now, normally, you would expect to see a collection name followed by a dot(.) and then the specific object (i.e. ADODB.Recordset), but if there's just the one, and the code above works in vb, then this **should** work in vbscript with ASP.

:)
Paul Prewett
penny.gif
penny.gif
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top