Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Executing ActiveX form

Posted on 1998-12-01
5
Medium Priority
?
232 Views
Last Modified: 2010-04-09
How can I execute one ActiveX form within the browser?
What I need to include in my HTML page to run this OCX?

Regards.
0
Comment
Question by:sergio_2001
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 1

Expert Comment

by:bbangerter
ID: 1840145
The easiest way is to use Microsofts Design Time ActiveX Control Pad (available for download from Microsofts site - sorry I don't know the exact URL to get to the correct download page).

But you'll end with somethink like the following in your HTML page

<OBJECT ID="myControl" WIDTH=100 HEIGHT=51
 CLASSID="CLSID:F0A59CA5-B599-11D0-836B-0004ACFCB2B9">
    <PARAM NAME="myParam1" VALUE="myValue1">
    <PARAM NAME="myParam2" VALUE="myValue2">
</OBJECT>

The ClassID is the tricky part.

This is probably going to be information than you want or need, but here goes....

Using the ActiveX control pad is the easiest way to get the ClassID.

But if you have Visual Basic you can include the control in a VB form, then open the .frm file in a text editor and look for a line like
Object = "{F0A59CA5-B599-11D0-836B-0004ACFCB2B9}#2.0#0}"; "myControl.ocx"
The part between the {}'s is your ClassID.

You can also run RegEdit from 'Start... Run... RegEdit' and then do a search (ctrl-f) on the name of your control (e.g., myControl).  The very first entry in the registry should show the class ID in {}'s.

The hardest method is using VC++.
If you are using VC++ you can insert the control into a project, open the newly generate header file, and look for something like.
static CLSID const clsid
                  = { 0xf0a59ca5, 0xb599, 0x11d0, { 0x83, 0x6b, 0x0, 0x4, 0xac, 0xfc, 0xb2, 0xb9 } };
            return clsid;

You'll note that by stripping off all of 0x and inserting dashes in the correct character positions you end up with
F0A59CA5-B599-11D0-836B-0004ACFCB2B9
remembering that this last section is a 12 character code, and may need leading zeros.

Presumably other Microsoft products that are capable of working with ActiveX controls have similar methods of determining the Class ID.
0
 

Author Comment

by:sergio_2001
ID: 1840146
bbangerter,

Your comment is correct. That's what I want.
Please send-me the answer to grade you.

Note: I done um activeX form using delphi. Using your answer I got to introduce the activex form in the html page but the form don't show properly. What should be?!?!?!?

thanks
0
 
LVL 1

Accepted Solution

by:
bbangerter earned 150 total points
ID: 1840147
Answer to above for getting the ActiveX control to work.

As for the form not showing properly, could you clarify what it is doing?
0
 

Author Comment

by:sergio_2001
ID: 1840148
I can see the space used for the activeX within the browser but I just see that litlle default icon at upper left side.
I hope to be clear....
thanks...
0
 
LVL 1

Expert Comment

by:bbangerter
ID: 1840149
Yes I do know what you mean, now if I can just remember how to fix it :).

What ActiveX control are you trying to use?  Is it a custom one or one built by say Microsoft or IBM or some other 3rd party developer?  Are there any properties within the control that determine whether or not to display the user-interface?  Any sizing properties to determine the size of the UI?

Also, just realized I'm getting charged 5 points to come in here and make comments (no big deal), but if we could move this to either a new question in experts-exchange or to private email (fanatic@aros.net) I'd appreciate it.
0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
Find out what you should include to make the best professional email signature for your organization.
In this tutorial viewers will learn how add a scalable full-width header using CSS3. Create a new HTML document with an internal stylesheet. Set a tiled background.:  Create a new div and name it Header. Position it with position:absolute at the top…
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question