background image
<< Instrumentation method | The Coverage Dictionary >>
<< Instrumentation method | The Coverage Dictionary >>

Instrument a secondary application

Instrumenting Visual Basic Source Code
3-9
3. To instrument a secondary application in addition to the main application, click
Add and select its .vbp file. Leave the check box next to the file path selected.
If you add secondary files to instrument, be sure to add the .vbp file for the main
application first, so it is at the top of the Visual Basic project files list.
4. To leave a listed .vbp file uninstrumented, clear its check box.
5. After you instrument the source files, you must rebuild the executable file. To
rebuild the executable file automatically from instrumented source files, leave
the Rebuild after instrumenting source check box selected.
6. If the path shown in the Path to Visual Basic box is incorrect, enter the correct
path to your Visual Basic executable file.
7. To remove a .vbp file for a secondary application from the Visual Basic project
files list, click the file path, and then click Remove.
8. Make sure that all of the files that you want to instrument, and no others, are
listed and checked, and then click Instrument.
If Visual Basic cannot rebuild the executable file, do the following:
a. Clear the Rebuild after instrumenting source check box.
b. Click Start VB.
c. Determine and correct the cause of the problem.
d. Rebuild the executable file manually.
e. Save the project, and then quit Visual Basic.
9. After instrumentation is completed and the executable file is rebuilt, click Close.
NOTE: If you specify a secondary application to instrument, TestFactory
automatically adds its executable file to the list of executable files to map. For
information about mapping secondary applications, see Mapping Secondary
Applications
on page 4-69.
NOTE: We strongly recommend that you use the automatic rebuild option.
If you clear the Rebuild after instrumenting source check box, you must
rebuild the .exe file in Visual Basic while the Instrument Source Code dialog
box is open. Otherwise, TestFactory does not save the instrumentation.
NOTE: If you still have problems making the executable file, make sure that
you can build the project using just Visual Basic.