LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Bug when updating a type def Enum

Hello everyone,

 

I have been experiencing a weird bug for a while now in the main VI of my program: after adding conditions to an Enum (by updating the type def), the main VI in which this Enum is used (the Enum defines the While loop conditions as shown in the image) is completely shifted, and I end up having diagonal cables and shifted elements in every conditions. In addition, every actions performed on the diagram shift the code to the left, and it eventually stops after few iterations. 

 

Have you ever encountered this bug before ? 

I am using LabVIEW 2019 32bits with Windows 10. 

 

Thanks in advance,

Sam

 

Download All
0 Kudos
Message 1 of 17
(419 Views)

Hi Sam,

 


@Samdub19 wrote:

I have been experiencing a weird bug for a while now in the main VI of my program:


Have you tried to edit a revision of your VI that is older then "for a while now"?

(I guess you use a SCC tool, do you?)

 


@Samdub19 wrote:

Have you ever encountered this bug before ? 


I have seen similar behaviour when the VIs had a (too) large block diagram.

What are the metrics of your VI?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 17
(416 Views)

I've seen something similar, but never diagonal wires!

Shifted elements sounds like you add or shift Items in the middle of the Enum, that's always dangerous and requires you to be extra careful.

If the VI has been corrupted, which the diagonal wires could point to, you can try to copy the entire Block diagram to a new VI and see if it behaves better.

Source Code Control - SCC, is built for these instances, assuming you remember to check in every so often.

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 3 of 17
(387 Views)

When editing enum typedefs, I don't make a bunch of changes, then apply.

I do "Apply Changes" after each individual change.  It's cumbersome, but it reduces headaches.

Message 4 of 17
(331 Views)

@paul_a_cardinale wrote:

When editing enum typedefs, I don't make a bunch of changes, then apply.

I do "Apply Changes" after each individual change.  It's cumbersome, but it reduces headaches.


To expand on that, if I want to add an item to the middle, I first add it to the bottom, apply changes, and then move it and apply changes.

 

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
Message 5 of 17
(327 Views)

Hi Gerd,

 

Yes I use an SCC tool and we can see that this problem does not occur in an older version of VI, without really understanding why.

 

I will try to reduce the block diagram to see if the problem still occurs.

 

Thank you !

0 Kudos
Message 6 of 17
(305 Views)

Hi Sam,

 


@Samdub19 wrote:

I will try to reduce the block diagram to see if the problem still occurs.


What are the metrics of the VI?

Tools menu -> Profile -> VI metrics, enable statistics for diagram and look for diag width/height…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 7 of 17
(302 Views)

Hi Gerd,

 

It seems that I don't have this option in my LabVIEW 2019. Is there an other way to obtain such informations ?

 

Thank you.

0 Kudos
Message 8 of 17
(295 Views)

Hi Sam,

 

tools->profile->VI metrics is already part of the base edition IMHO:

 

You can show the navigation window (ctrl-shift-n) and show a screenshot of that window. Then one can compare screen/window size with diagram size:

The white background shows a FullHD screen, so the block diagram is slightly larger than the screen. (A QMH with several handler loops…)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Download All
0 Kudos
Message 9 of 17
(291 Views)

My own "Rule of Thumb" (which I learned from reading, several times, Peter Blume's "LabVIEW Style Book" cover-to-cover) is to make all of my VIs fit on a standard Laptop screen.  Sometimes this involves making a parallel loop into a sub-VI taking (only) 32 x 32 pixels, but this lets you concentrate on the Top Level vi ...

 

Notice Gerd's picture shows his example is pretty close -- I'd call it about 1.3 x 1.3 Laptops.  We've seen some Block Diagrams that are 15 x 5 Laptops, clearly a challenge to manage (unless you have 75 monitors available).

 

Bob Schor

0 Kudos
Message 10 of 17
(147 Views)