LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

ActiveX Advanced control of external application.

Hi all:
There is an application that I've automated using activeX control. I use Labview 7.0 on windows XP.

It works great. When I run my labview code (It's a standalone application), it automatically starts the external application and runs it. What I wish to do is mask everything else other than my code. In short, my code should be the only visible window and whatever window opens because of my program should be invisible or be suppressed. Is there any way to do this ?

Kudos are the best way to say thanks 🙂
0 Kudos
Message 1 of 12
(4,087 Views)
hi

i'm quite sure there'a a llb for doing such things. search the knowledgebase and this forum.

otherwise:
there are APIs in user32.dll like "FindWindow","ShowWindow" and "CloseWindow" which let you control the window appearence (you need to know the windows title). please refer to microsoft (e.g. at www.msdn.com). but: search the KB, i've seen that before!

best regards
chris
Best regards
chris

CL(A)Dly bending G-Force with LabVIEW

famous last words: "oh my god, it is full of stars!"
Message 2 of 12
(4,085 Views)
Hello,

The APIs in user32.dll are one way to control the appearance of the external application windows. You can also right-click on the ActiveX application and select Create -> Property -> Visible. If you wire a constant Boolean False to this property, the external application windows will be invisible. You must also wire the automation refnum of the application to the reference input of the node.

Caroline
National Instruments
Thanks,
Caroline Tipton
Data Management Product Manager
National Instruments
0 Kudos
Message 3 of 12
(4,070 Views)
Thanks for your suggestions. The hide window.vi utility does not hide it completely. There is a taskbar entry of the window.

I tried to see if I can use property node for the activex application. That application does not have any properties at all. Only methods. Any tips ?

Kudos are the best way to say thanks 🙂
0 Kudos
Message 4 of 12
(4,064 Views)
What type of application is it?

Caroline
National Instruments
Thanks,
Caroline Tipton
Data Management Product Manager
National Instruments
0 Kudos
Message 5 of 12
(4,061 Views)
It is an application which runs few experiments. So basically I use automation refnum and automate that application using my VI. There are 2 annoying pop-up windows which tell you about the status of the experiments. I want to close them. Tried using Hide windows.vi, but does not do it completely.

Kudos are the best way to say thanks 🙂
0 Kudos
Message 6 of 12
(4,060 Views)
At this point we have run out of immediate options. If the ActiveX server does not have the property to hide the windows and the Hide Window vi is not working as you would like it, there is really nothing else than can be done on the LabVIEW side of things. Again, you should look into options such as "ShowWindow" in the APIs in user32.dll. You can find more information on these options at www.msdn.com.

Thanks,
Caroline
National Instruments
Thanks,
Caroline Tipton
Data Management Product Manager
National Instruments
0 Kudos
Message 7 of 12
(4,040 Views)
"ShowWindow" is the API behind "Hide windows.vi" which Maximus00 has tried.

I think it's the extended window style causing the problem.

George Zou
http://gtoolbox.yeah.net
George Zou
0 Kudos
Message 8 of 12
(3,986 Views)
Hi Maximus,
Could you tell me where I can find Hide Window.vi? I had it in my proram and when I changed computers (installed the 7.1.1 version) I could not find the vi. I am also looking for Get Window RefNum.vi If you know anything about their whereabouts, I would greatly appreciate your help. Thanks! IBAHKA
0 Kudos
Message 9 of 12
(3,859 Views)
Hi Ibahka

I've attached the Zipped folder lvwutil32.zip

It must have all the VIs you need...If you cannot use this search for Lvwutil32 on NI site and you should get it since that's where I can mine from

Hope this helps !

sridhar

Kudos are the best way to say thanks 🙂
0 Kudos
Message 10 of 12
(3,857 Views)