Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


How to call ActiveX objects methods in vbscript ?

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,621
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> How to call ActiveX objects methods in vbscript ?
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 How to call ActiveX objects methods in vbscript ? - 5/13/2002 7:36:04 AM   
  BenTrasys

 

Posts: 1
Score: 0
Joined: 5/13/2002
From:
Status: offline
Hello,

Here is the reason of my concern :

I've written an activeX control that I've registered using the "regsvr32" DOS command. Then I've included this control in an html page thanks to "ActiveX Control Pad". When I launch the html page, the activeX object displays properly and reacts correctly on the events for which I have written code in Visual Basic ( Private Sub Button1_Click() for example ). THE PROBLEM IS that there are some public procedures/functions of the ActiveX object that I would like to call in the vbscript section of my html page. When I launch the script wizard in the activeX control pad, I can see the public variables and procedures or functions of my ActiveX control. Those I want to call are indeed among them ... but I don't succeed in calling them !
This is what my code looks like :




New Page


CLASSID="CLSID:9EC1F059-6E9C-4803-A0AF-942EB4A0271D">






The line of code that bothers me is :
call UserControl1.setMail("blablabla")
where "setMail" is the name of a public procedure of my ActiveX object.

This line doesn't do what it is supposed to !
( It doesn't do anything actually ).
Also, because of this line, the following vbscript lines seem not to be executed.

Thanks for helping ...

Benjamin.
 
 
Post #: 1
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> How to call ActiveX objects methods in vbscript ? Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts