Board index » cppbuilder » VB ActiveX import problems

VB ActiveX import problems

I need to import a collegue's VB6 acitveX control into my pallete on
BCB5. I ran the usual import routines that work for the ActiveX
controls that I have built using VC on his controls but his control
never appears on my pallete.
When I examined the generated files for his control vs. my controls, I
noticed that my controls contain a "package" statement while his did
not.
Is there something wrong with his control that the IDE could not
generate the required code to allow his control to fully import.?

TIA

 

Re:VB ActiveX import problems


Hi,

Quote
> I need to import a collegue's VB6 acitveX control

There was an issue with VB control flags like Creatable
being OFF. Basically, BCB4 ignored some but when BCB5
started obeying them, problems showed up. There are
switches to tlibimp (the command line tool for importing
type libraries and ActiveX controls) that will ignore
these flags. Make sure the patch is applied and try a
command line import like:

 tlibimp -C+ -Yu -Ya -H+ -Q+ -R+ SomeName.ocx

Then files are generated that you can add to a
package and install in the IDE.

--Craig

Re:VB ActiveX import problems


Thanks Craig-
That helped a lot.

I notice that the generated files have some warings that state:
//
// The code generated by the TLIBIMP utility or the Import|TypeLibrary

// and Import|ActiveX feature of C++Builder rely on specific versions
of
// the header file UTILCLS.H found in the INCLUDE\VCL directory. If an

// older version of the file is detected, you probably need an
update/patch.
//
#error "This file requires a newer version of the header UTILCLS.H" \
       "You need to apply an update/patch to your copy of C++Builder"

Is there another patch that I need.? ( I have applied patch 1 to the
PRO version that I am running..)

On Fri, 12 Jan 2001 17:24:45 -0800, Craig Farrell

Quote
<cNO_SPAM.please.farr...@insprise.com> wrote:
>Hi,

>> I need to import a collegue's VB6 acitveX control

>There was an issue with VB control flags like Creatable
>being OFF. Basically, BCB4 ignored some but when BCB5
>started obeying them, problems showed up. There are
>switches to tlibimp (the command line tool for importing
>type libraries and ActiveX controls) that will ignore
>these flags. Make sure the patch is applied and try a
>command line import like:

> tlibimp -C+ -Yu -Ya -H+ -Q+ -R+ SomeName.ocx

>Then files are generated that you can add to a
>package and install in the IDE.

>--Craig

Re:VB ActiveX import problems


Quote
> #error "This file requires a newer version of the header UTILCLS.H" \
>        "You need to apply an update/patch to your copy of C++Builder"

Check that BCB5 is first on the OS PATH setting. tlibimp.exe
comes with previous BCB's and also with Delphi.
Also, you could check the time and date of the utilcls.h files
that you have. I think if the patch sees an edited updated one
it leaves it alone.

--Craig

Other Threads