Nov 23, 2009

Activex In Html - anyone know how to use ActiveX control in WebApp?

free web hosting
Open Discussion & Free Web Hosting > Computers & Tech > Programming > Scripting > JavaScript

Activex In Html - anyone know how to use ActiveX control in WebApp?

PureHeart
I'm writing a web application for language learning and I'd like to use the Speech API from Microsoft for speech recognition. Therefore, I need to embed an ActiveX control to the web page (html file). The questions are:

1. How to embed this ActiveX control to the web page, I don't know the class id of that control. For a RealPlayer, I would use
CODE
<object classid="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA" width="32" height="32"></object>

and in this case, i need the value for classid.

2. In case the user (client) doesn't have that activeX control, how to have it downloaded automatically (with permission)?

3. How to handle the events of the control.

Link: http://www.microsoft.com/speech/default.mspx
Download: http://www.microsoft.com/downloads/details...;displaylang=en

PS: I'm new to JS. Please answer with code.

 

 

 


Comment/Reply (w/o sign-up)

TavoxPeru
QUOTE(PureHeart @ May 10 2007, 07:53 AM) *
I'm writing a web application for language learning and I'd like to use the Speech API from Microsoft for speech recognition. Therefore, I need to embed an ActiveX control to the web page (html file). The questions are:

1. How to embed this ActiveX control to the web page, I don't know the class id of that control. For a RealPlayer, I would use
CODE
<object classid="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA" width="32" height="32"></object>

and in this case, i need the value for classid.

2. In case the user (client) doesn't have that activeX control, how to have it downloaded automatically (with permission)?

3. How to handle the events of the control.

Link: http://www.microsoft.com/speech/default.mspx
Download: http://www.microsoft.com/downloads/details...;displaylang=en

PS: I'm new to JS. Please answer with code.

If i remember correctly the class id for the control depends on the object itself, for example if you develop that control with VB its class id is generated by VB when you compile and create it by using the Application Setup Wizard.

In case the user doesn't have that ActiveX control installed, it can be downloaded automatically and installed in his machine by using a cab file, the location from where it can be downloaded is specified by a CODEBASE parameter of the object tag, this cab file must be created by you and stored in your webserver, as you guess, the value of the codebase is an URL relative to the location of your html page.

To handle the events of the control you can do it as usual for example if your object is a button to handle the click event of it you can use something like this:
CODE
<html>
<head>
<title>Title</title>
</head>
<body>
<p>some text</p>
<object classid="clsid:9999-99D5-00AA00AA00" id="BtnHello">
</object>
&lt;script language="VBScript">
Sub BtnHello_OnClick()
  MsgBox "BtnHello was clicked"
End Sub
</script>
</body>
</html>


Please, forgive me if i'm wrong because i dont use visual basic for a long long time, so take this as a brief help.

Best regards,

 

 

 


Comment/Reply (w/o sign-up)

PureHeart
QUOTE(TavoxPeru @ May 11 2007, 02:58 AM) *
If i remember correctly the class id for the control depends on the object itself, for example if you develop that control with VB its class id is generated by VB when you compile and create it by using the Application Setup Wizard.


The problem is that I'm not the author of that control (Microsoft is). Do you know how to get the class id of any control store in an ocx or dll file.

Comment/Reply (w/o sign-up)

TavoxPeru
QUOTE(PureHeart @ May 11 2007, 06:24 AM) *
The problem is that I'm not the author of that control (Microsoft is). Do you know how to get the class id of any control store in an ocx or dll file.

You find that information on the Registry, i don't remember exactly where but i guess that it is located under the HKEY_LOCAL_MACHINE\SOFTWARE\Classes hive, inside there you will find lots of keys so you probably have to dig a lot until you find it, try to use the search function located under the Edit menu to perform this search. Also pay attention to the Interface key located under this hive because inside it you can also find the information.

Best regards,

Comment/Reply (w/o sign-up)

PureHeart
I've spent 2 hours searching but nothing found. Is there a way to get the classid right from the ocx file?

Comment/Reply (w/o sign-up)

TavoxPeru
QUOTE(PureHeart @ May 13 2007, 01:18 AM) *
I've spent 2 hours searching but nothing found. Is there a way to get the classid right from the ocx file?

Since a few years i dont programming with VB, so, my apologies PureHeart because the path that i told you from where to search is partially wrong, the correct place to search for the CLSID of an ocx file is located at

HKEY_LOCAL_MACHINE\SOFTWARE\Classes

inside there search for the ActiveX control by using it's file name as the parameter, for example if your ocx is named MyOcx.ocx, Then, simply go to

HKEY_LOCAL_MACHINE\SOFTWARE\Classes\MyOcx\CLSID

and get the value from there.

In case you dont know this, generally the ocx's files are located at %WINDIR%\System32 folder.

Sometime ago i use an application for this situation, some system tool called Activex Pad or something like that.

Finally take a look for this good article: Dynamic web pages with ActiveX and VBScript.

Best regards,

Comment/Reply (w/o sign-up)

(G)Biren
Classid prob
Activex In Html

hi,

I have a file which uses activex control with the classid tag. It runs fine when its on my machine.

however when I put the file on web server ,  the controls do not load. Thus its showing me a cross mark on my browser.

Does ne1 have an idea about this?

Any help is appreciated !

-reply by Biren

Comment/Reply (w/o sign-up)


Got an Opinion! Express your Views! (no registration):-
Add your Reply/ Opinion/ Views/ Comments/ Suggestion/ Questions/ Queries etc.
Posts with decent grammar & English will be accepted and please refrain from profanities.
For asking a Question, We recommend you to sign-up (for free) so that you can track the topic easily.

Nature of your Post*: Opinion/ Reply/ Comments
Question/Query
Feedback to us.
       
Name   Email
Title/Question*

This textarea will convert to Rich-Text automatically (IE, Firefox, Chrome)


See Also,

*SIMILAR VIDEOS*
Searching Video's for activex, html, activex, control, webapp,
advertisement



Activex In Html - anyone know how to use ActiveX control in WebApp?

Affordable Web Hosting, Low cost Web Hosting - ComputingHost.com