Solved

How to reset the executable for DLL testing

Posted on 2001-07-12
5
184 Views
Last Modified: 2006-11-17
I'm working on my first ActiveX DLL in Visual Basic.  Not knowing any better, I kept compiling it, open a test VB project that called the DLL, and ran my tests on the DLL that way.  I was peppering the DLL code with msgbox and log print statements to debug portions of it because I couldn't fathom how to test it otherwise.

  I then noticed the RUN arrow sitting up there while editting the DLL code.  I clicked it and it prompted me to ask which executable I wanted to use the test the DLL.  I thought this was GREAT!

  But after filling in all the prompts and running it, it bombed because I forgot to add some run-line parameters with the executable name....

QUESTION: How do I bring up that dialog box to change the executable to test the DLL?    I swear I clicked on everything I could find.

Thanks
0
Comment
Question by:EasyAim
5 Comments
 
LVL 44

Accepted Solution

by:
Arthur_Wood earned 50 total points
ID: 6277998
build a project group that includes the DLL project AND a standard project that will test the DLL.  in the Project Eplorer, right click on the Standard Project and select Set As StartUP.

Make sure that in the Standard project member of the group, you have included the Reference to the DLL project.  Now you should be able to run the Standard projecvt, and step, as necessary, into the code of the DLL  project.  

That is one of the greeat strnegth of VB, and the main use of Project Groups.
0
 
LVL 8

Expert Comment

by:Dave_Greene
ID: 6278001
An even easier way to test you DLL is to open it in one instance of VB. Once opened press the play button.  Nothing will happen in the DLL project (This is good!) then in another instance of VB open whichever EXE you want to call the DLL with.  Now when you run the exe and create the DLL object, the other instance of VB will get focus and you can debug the DLL.  

Although it is much easier to add the DLL project to an EXE project (Creating a Group) and test the DLL that way.  

Good luck

-Dave
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 6278041
If i understood, cight click on test project and choose "Set as initial"(i don't know the exact menu item since i have vb in spanish.)
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 6278059
It should be the choice at the top of the Pop-Up Menu that is displayed when you right click on the Project Name of the Standard Project.
0
 

Author Comment

by:EasyAim
ID: 6278754
Arthur Wood's explanation works well.  It is going to save me tons of time now.  I appreciate everyone's response.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
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 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…

912 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

24 Experts available now in Live!

Get 1:1 Help Now