...

View Full Version : Vbs to asp ??



kdwebsol
09-16-2005, 06:53 PM
I have a vbs script when I run at the dos prompt creates rooms in our chat client. How can Is it possible to convert the vbs file to asp so we can create the rooms using a web page?

Vbs file
set theObj = CreateObject("HotComm.CRManager")

If theObj.RoomExists("MoeXP") Then
WScript.Echo "Room MoeXP Exists"
Else
WScript.Echo "Room MoeXP Does Not Exist"
End If

theArray = theObj.GetRoomList()
If IsArray(theArray) Then
For x = LBound(theArray,1) To UBound(theArray,1)
WScript.Echo "Room '"&theArray(x)&"'"
Next
End If

If theObj.CreateRoom("TestRoom","owner@hc.com","123","abc","a1",11448,140,5,50) Then
WScript.Echo "Room Creation Succeeded"
Else
WScri

Thanks!

nikkiH
09-16-2005, 07:52 PM
You'll have problems with this:
CreateObject("HotComm.CRManager")

That object has to exist on the server, and it has to be allowed to create it.
You may need to set that up with your IIS admin.

And change any wshell/wscript objects. They are for windows shell.
Use response.write to echo out stuff to the browser.

The client/server thing is different from an all client application. You may run into other "gotchas".

kdwebsol
09-16-2005, 09:02 PM
You'll have problems with this:
CreateObject("HotComm.CRManager")

That object has to exist on the server, and it has to be allowed to create it.
You may need to set that up with your IIS admin.

And change any wshell/wscript objects. They are for windows shell.
Use response.write to echo out stuff to the browser.

The client/server thing is different from an all client application. You may run into other "gotchas".

Thanks forthe info! Were can I find info on were to find how to create an object on server 2003?

Thanks,
Ken

nikkiH
09-16-2005, 09:29 PM
A little digging on other 3rd party libraries shows install exe files that usually do the setup.
An example... (http://support.microsoft.com/?kbid=898633&SD=tech)

Do you have the installer for that application?

kdwebsol
09-16-2005, 10:18 PM
I have the install file but some files were changed to alllow the vbs file to create the rooms. If I find out what files create the rooms is there an easy way to set them up like an OBDC?

nikkiH
09-16-2005, 10:31 PM
You've lost me on that one.
ODBC is for database interaction.
I have no idea what "Creating a room" really means.
I think you may be comparing apples to oranges...not sure though.

Your goal is to get that object installed on IIS, then you won't have to change that part of the code a bit.

kdwebsol
09-16-2005, 10:59 PM
What I was referring to when I said an easy way like ODBC was like setting up a DNS to connect a database. All I have to do is set it up and then the asp script know were to go when I use is Conn = DSN=dnsname;UID=user;PWD=password;DATABASE=database"

Is there a admin utility that I can use to create objects to be linked to the chat application? When I use set theObj = Server.CreateObject("HotComm.CRManager") I receive this error:
error '80004005'
/test2.asp, line 13
Line 13 id the CreateObject line.

nikkiH
09-16-2005, 11:22 PM
Yeah, once you get it installed, you can just instantiate it.
And no, I don't know of any tool to do it.
Read the article I linked for hints. It will be application specific, since it involves registry changes.
You should really try to find the installer, though.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum