| || |
Visual Basic objects and procedures
I searched the archives and nothing turned up for this question. This has been bugging me for a while, and I've done workarounds but I would like to find the real solution.
I am attempting to include various VB modules that I wrote in Visual Studio as well as freeware code that other people wrote. The code frequently uses either constants or VB methods that are not defined / available in test partner.
Two examples I came across today are as follows:
Constants included in 'Visual Basic for Applications' MSVBVM60.dll and standard functions such as 'App.Path' included in 'Visual Basic runtime objects and procedures' VB6.OLB. The code works fine in Visual Studio 6, but fails to compile in test partner (Since the references are not available).
Attempting to include a reference in test partner causes test partner to crash. Has anybody found a way to make test partner more like visual studio, or at least get access to VB commands and constants so existing VB code does not need to always be rewritten?
Re: Visual Basic objects and procedures
I think you may just need to look a little deeper into the libraries that TP currently references and possibly a couple you are not familiar with yet.
I too wanted to use the VB6.olb for the clipboard object and had a crash. I found that this is a M$ issue and they will probably never fix it. To get around the problem I found fm20.dll which allows me to copy and paste to the clipboard.
Some of the VBA functionallity has been wrapped into TPOSI objects. Take a look at the TApp object in the TPOSI library. I think that is probably what your looking for to replace App.Path.
For the constants, I am not really sure. If you could be more specific maybe I could answer.
Hope this helps.