LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

XControl facede.vi - Events that are triggered when a new instance is opened.

HI All,
 
In a normal execution of XControl, I notice that following events are triggerd when a new instance of XControl is dropped on the front of a VI, or when a VI is opened which is owning the XControl. (In a sequencial order)
 
1. Data change event.
2.Direction change event.
3.Display state change event.
4.Execution state change event.
5. Time out event.
 
But in my application, after all the above events are triggered, once again the facade vi triggers the "Data change event" . Note that this is the second time that XControl triggers the facade VI after execution of all the above mentioned events(including time out).
 
I am wondering why this Data change event triggers once again. I dont even run the owning VI.
 
I also have a sub panel on the front panel which is owning the XControl. Will this cause any problem?
 
Has anyone come across this situation?
 
Any suggestions most appreciated.
 
Thanks.
 
 


Message Edited by Vsh on 03-25-2008 09:55 AM
0 Kudos
Message 1 of 16
(3,987 Views)

Hi,

On what occasions the "data change" event occurs apart from dropping a new instance of the XControl, value was written to the XControl's terminal, local or value property.?

if anybody could suggest any answer/links for this would be helpful.

Thanks

0 Kudos
Message 2 of 16
(3,963 Views)
Ok, here we go,
 
After 2 days of scratching my head (almost having a bald head), I figured out that, if the data type of the XControl is an array, and you create a reference of any other control on the owning (calling) VI of Xcontrol, the data change event executes twice when opened the owning VI. (looks very simple isnt itSmiley Indifferent?)
 
The reference has got no relation with the data type of XControl being an array. It can be any reference to the controls or indicators existing in the owning VI.
 
Strange.
 
Is there any work around for this?.. 
 
Here is an example illustrating the same.
 
Open the project XControlTest.lvproj, open the vi TestVI.vi from the project, a break point is put in the facade.vi's block diagram. which shows that it executes twice (executing the data change event in the second execution). Now delete the references from the block diagram of the "TestVI.vi" save, close the vi and open it again. Now you can see that facade vi executes only once.
 
Also change the data type to scalar, create the reference in TestVI.vi  you can observe that the execution is very much normal.


Message Edited by Vsh on 03-26-2008 12:56 PM
0 Kudos
Message 3 of 16
(3,937 Views)
Is there a work around??Smiley Sad
0 Kudos
Message 4 of 16
(3,904 Views)

Hi Vsh,

I am stepping in here only because nobody else has responded. I have submitted a request to have an Appl Eng from NI take a look at your issue.

On the surface it sounds similar to the bug that we discussed in this thread but may be a new issue.

XControls are still new teritory for me so please accept my appologies for not being able to say more to help.

I do appreciate you bring this topic up and allowing us to learn what is going on or to nail a previously un-reported bug.

I'll watch this thread for updates.

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 5 of 16
(3,897 Views)

Hi Ben,

Thanks for the link, but I dont think I am having a similar issue here, I had the same issue before and I was able to resolve it.

The only problem here is, facade vi executes twice (when opened the VI containing the XControl), because, the datatype of XControl is an array and I have a control reference (of some other control) in the block diagram which is owning the XControl.

Anyway, I am trying for a work around. Will update you the progress.

ThanksSmiley Happy

(--- by any chance if this issue is reported as a bug, will NI refund the amount for 2 days I have wasted?? Smiley WinkSmiley Very HappySmiley Very Happy



Message Edited by Vsh on 03-27-2008 08:33 AM
0 Kudos
Message 6 of 16
(3,885 Views)
"

(--- by any chance if this issue is reported as a bug, will NI refund the amount for 2 days I have wasted??

"

My customers have been asking the same question for the past nine years. The answer has always been,

NO! Smiley Mad Smiley Wink

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 7 of 16
(3,880 Views)

Ok Smiley Very HappySmiley Very HappySmiley Very Happy

(That should have been under "Submit feedback" line of the LV help!!

No refunds if any bugs found!)

0 Kudos
Message 8 of 16
(3,874 Views)
Hi Vsh,

XControls is definitely an area which not many people have expertise in.
I am glad I'll be learning how it works.

I will be looking into this issue and get back to you asap.

Thank you BenNi for filling in
Van L
NI Applications Engineer
Message 9 of 16
(3,839 Views)
I have successfully replicated this issue on my side and tried several other things as well.

I have already talked some LabVIEW experts and we are looking deeper into the behavior of XControls and how other references interact with it.

Vsh, I am curious how this behavior is affecting your application.

Thank you for your patience
Van L
NI Applications Engineer
Message 10 of 16
(3,807 Views)