Solved

Debug OCX / DLL Without Using Project Group (with MATLAB)

Posted on 2003-10-23
14
1,356 Views
Last Modified: 2013-11-26
I have an ActiveX OCX, which is merely a wrapper for an ActiveX DLL, that I want to debug. I am instantiating it in a MATLAB environment. If I fire up the compiled OCX, all works well. However, how do I get to debug in the OCX (I cannot make it a part of a VB project group because the MATLAB is a separate EXE environment). When I try it, when the MATLAB tries to fire up the OCX, it generates an error that the OCX could not be created.
0
Comment
Question by:GivenRandy
  • 6
  • 4
  • 3
  • +1
14 Comments
 
LVL 69

Expert Comment

by:Éric Moreau
ID: 9609619
Can't you load your OCX project source code into VB6 IDE, add breakpoints, and press F5 to start it ?
0
 
LVL 69

Expert Comment

by:Éric Moreau
ID: 9609623
Then you start MatlLab.
0
 
LVL 9

Author Comment

by:GivenRandy
ID: 9609923
Yes, but when MATLAB tries to start an instance, it says that it cannot do it. When it is compiled, it works fine (the compiled component is registered). In other cases, when debugging in VB as a group, it handles using the debug version. However, MATLAB seems to think that the compiled one is not registered and the debug one is non-existant. There is probably something simple in the setup that I am forgetting (I thought that I had done this before).
0
 
LVL 9

Author Comment

by:GivenRandy
ID: 9610051
I get this error:

>??? Error using ==> actxcontrol
>Control creation failed.

It should have recognized it (I selected the "Start Component" option).
0
 
LVL 69

Accepted Solution

by:
Éric Moreau earned 200 total points
ID: 9610933
Maybe that Matlab may not reference a virtually registered component! Not all application can do it!
0
 
LVL 26

Expert Comment

by:EDDYKT
ID: 9613544
have you set binary compability on your OCX?
0
 
LVL 26

Expert Comment

by:EDDYKT
ID: 9613551
and then use project group
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 9

Author Comment

by:GivenRandy
ID: 9613622
EDDYKT, it is not part of a group nor can it be added (unless I am missing something). The MATLAB is an outside executable from a third-party.
0
 
LVL 26

Expert Comment

by:EDDYKT
ID: 9613634
Ooops, What is the error anywaqy?
0
 
LVL 28

Assisted Solution

by:AzraSound
AzraSound earned 100 total points
ID: 9615387
On the debugging tab, you usually select "Wait for components to be created" in these scenarios (or maybe it only applies to ActiveX DLLs).  Can you run your ActiveX DLL and debug in this manner?
0
 
LVL 9

Author Comment

by:GivenRandy
ID: 9616413
I tried that, too. It is not acting "normal" (which is not unusual for MATLAB, from my experience).
0
 
LVL 26

Assisted Solution

by:EDDYKT
EDDYKT earned 200 total points
ID: 9618705

On debugging tab

Can you use start program with  your exe on the box?
0
 
LVL 9

Author Comment

by:GivenRandy
ID: 9626997
I tried starting the program with the exe as well, same result.
0
 
LVL 9

Author Comment

by:GivenRandy
ID: 9627008
Although I would like to get a solution that worked, it very likely is a MATLAB problem (as mentioned above). I will offer more points as needed.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

747 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

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now