Solved

ActiveX

Posted on 2004-08-16
3
303 Views
Last Modified: 2013-11-20
Hi,
 Can any one tell me how to develop  an ActiveX control using VC++???

Thanx in advance
0
Comment
Question by:ArunaK
[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
  • 2
3 Comments
 
LVL 3

Expert Comment

by:jlsjls
ID: 11818875
Using Microsoft Visual C++ :
File - New - MFC ActiveX ControlWizard - Fill in name of component - Next - Finish

Now you've created a framework for an ActiveX control.
In order to set properties :
View - Classwizard - Automation - Add property : fill in name and type of property (Get/Set property)

In order to create methods :
View - Classwizard - Automation - Add method : fill in name and returntype

Now you'll need to add the implementation of the method/property. You can use the ClassView to go to the method/property.

Hope this helps.
jlsjls
0
 

Author Comment

by:ArunaK
ID: 11818895
hi,
thanx for ur response ya after creating the .ocx component as u told how can i use it in a client application???

Thanx in advance
0
 
LVL 3

Accepted Solution

by:
jlsjls earned 50 total points
ID: 11819301
This depends on the client application (language).
You' ll need to register the control first.

Example in Visual C++ using MFC :
File - New - MFC AppWizard - Fill in name of component - Next - Dialog Based- Next - support Automation/ActiveX Controls - Finish

Add Control to application :
In DialogEditor : Project - Add to project - Components and controls - Registered ActiveX Controls - Browse to component and Insert (some classes need to be made).
Drag component on dialogbox and add membervariable for it in Classwizard. One can address methods and properties of the control.

One can follow simular operation in VB.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
ORA-01403: no data found 43 116
viewing source code from eclipse 13 111
countEvens challenge 2 117
Notepad++ Question 11 28
Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This video shows how to use Hyena, from SystemTools Software, to update 100 user accounts from an external text file. View in 1080p for best video quality.
Suggested Courses

752 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