Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ActiveX control not visible at runtime when placed in container 1

Status
Not open for further replies.

vaxman9

Programmer
Feb 26, 2002
80
US
Greetings all,

I am having an issue with a some 3rd party ActiveX controls when I place them within a container. I am creating a class that is based on a container. I place the 3rd party ActiveX control in the container. I have a couple of native VFP controls in the container.

When I place my new class on a form, all controls are visible. When I run the form, only the native VFP controls are visible, the 3rd party ActiveX controls are not. Using the debugger, I confirmed the controls exist, are enabled and visible.

If I place the 3rd party control directly on my form, it is visible at runtime.

Any assistance would be greatly appreciated.
msc

 

I suspect this is a problem with the specific controls you are using.

I have several classes that consist of ActiveX controls inside containers, and I've never had this problem. I use the Microsoft Listview and Treeview classes in this way. There is nothing special you need to do with those controls to make them visible.

Is it possible that the control is positioned outside the visible area of the host container? That's unlikely to be the case, given that you can see the control at design time, but you might have some code that moves the control with respect to the container. Might be worth checking.

The only other thing I can suggest is that you examine the properties of the control. Has it got a Visible property, or a Show method, for example?

Mike


__________________________________
Mike Lewis (Edinburgh, Scotland)

My Visual FoxPro site: www.ml-consult.co.uk
 
Thanks Mike,

The control is at Left=1, Top=1 in the container. If I copy it out of the container and drop it on the form, at runtime the one on the form is visible, but the one within the container is not.

I've tried toggling the visible property to On and Off (=.t./.f.) multiple times with no success. I've also try changing the Zorder, also with no success.

I hope to use these controls for an HMI I am working on for a PLC. The vendor has many VB examples, but unfortunately no VFP examples.

I found a note on the Universal Thread from 2004 someone posted indicating the same problem. I've dropped him a note and asked if he ever found a solution. I'll let you know if he did.

Thanks again for the quick response,
Matt
 
Follow up ...

I uninstalled the evaluation controls, unregistered the components and delete all OCX and DLLs. I went to the vendor's site, downloaded the latest evaulation of the controls, installed them and now everything is ok.

That's what I get for using an old version of the controls my client supplied me =P

Thanks again,
Matt
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top