From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Xcontrol Freezes VI when VI is launched from project

Hi,

 

I have an Xcontrol on my front panel.  Almost everytime I load the main VI none of the buttons will work and I cannot access the block diagram.

 

I must then unlock the VI, delete the xcontrol and replace the xcontrol on the front panel from the labview project in order for the VI to work.

 

Any ideas why it I have to got through the above process?

 

(In addition, I have two xcontrols and it only happens with one.)

Rgds,

Seán

0 Kudos
Message 1 of 6
(2,579 Views)

The problem is most likely a bug in your XControl.  Find the bug, fix it, and the problem will go away.

If you want a less sarcastic answer, you must provide more information (i.e. your code).

"If you weren't supposed to push it, it wouldn't be a button."
0 Kudos
Message 2 of 6
(2,546 Views)

Hi Paul,

 

I cannot supply the code as it is confidential.

 

The error only happens intermittently and I have been unable to debug.  I was hoping someone might be able to suggest typical areas that could be causing the issue.

 

Rgds,

Seán

0 Kudos
Message 3 of 6
(2,511 Views)

SeanJ wrote:

[...]none of the buttons will work and I cannot access the block diagram.[...]

Sounds like a dead lock with events. Is it possible that you have blocking calls in the event structure and/or assign multiple event structures to react on the same event?

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 4 of 6
(2,508 Views)

One technique I use sometimes is to add debugging code at a variety of places that logs a message to a file (messages indicate location in the code, e.g. "Starting SubVI 1").  Then when it hangs, inspecting the log file will help you narrow down where the problem is.

"If you weren't supposed to push it, it wouldn't be a button."
0 Kudos
Message 5 of 6
(2,502 Views)

@paul_cardinale wrote:

One technique I use sometimes is to add debugging code at a variety of places that logs a message to a file (messages indicate location in the code, e.g. "Starting SubVI 1").  Then when it hangs, inspecting the log file will help you narrow down where the problem is.


If available, i would rather use the Desktop Trace Toolkit (DETT) and include custom DETT messages in the code of the XControl. The reason is that i do get information "for free" (e.g. event structure execution, threading information, ...) additionally to the ones which are generated explicitly.

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 6 of 6
(2,499 Views)