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

x
?
Solved

A form in an ActiveX

Posted on 2004-04-01
3
Medium Priority
?
169 Views
Last Modified: 2010-05-02
Hi,

I've busted my but on this to no avail.

I want to put a form in an activeX and call it.

Should I create a dll or ocx? if a dll, how do I load it in my program?
0
Comment
Question by:StevenJames
[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 Comments
 
LVL 9

Accepted Solution

by:
dancebert earned 500 total points
ID: 10737761
Create a project of type ActiveX Dll (myProject).  Include a class (myClass) with a Public Sub (mySub).  Set the INstancing property of myClass to '5-multiuse'.  Add a form to the project.  In mySub put the code to show the form.  

Add another project (CallingProject) to the project group, this time of type Standard EXE.  Add a reference to myProject.  Somewhere in CallingProject, do something like this

dim o as myProject.myClass
set o = new myClass
o.MySub


0
 
LVL 3

Expert Comment

by:santosh26676
ID: 10738570
Yes I agree with dancebert. You could actually build the complete module (this is just for understanding purpose) and add as many form as you want. Just create the instance of the class (DLL) in the calling program and call the functions. Each function in DLL will perform some operations ( may be some calculations or loading a user interface).

0
 
LVL 4

Author Comment

by:StevenJames
ID: 10742072
Friggin beautiful man.

Thanks!
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Question has a verified solution.

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

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

597 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