LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Failure to recognize START REGION / END REGION pairs in CVI 2017

User-defined collapsible regions are created in CVI by enclosing the region with a START REGION / END REGION comment pair. This works for short sections of code, but I have found that longer regions (> ~200 lines) often fail to be recognized by the IDE as collapsible. It is a finicky behavior -- sometimes, but not always, I can collapse a few sub-regions and CVI will find the START / END pair. This newly-found region is remembered while CVI is running, but is forgotten upon exit. Using [View -> Collapsible Regions -> Collapse All] successfully finds all START / END pairs, but I don't want to collapse everything in my code. Is there a way to remedy this failure to find user-defined collapsible regions?

0 Kudos
Message 1 of 4
(2,317 Views)

Hi dnicholson,

 

I tried to reproduce the issue you were seeing in LabWindows/CVI 2017. I had 256 lines in between REGION START AND REGION END, but I was still able to collapse the region. I also tried several regions of 256 lines and also was not able to reproduce the behavior. Interestingly enough, when I close that code I wrote, and reopen it (all regions are expanded), collapsing one of the regions causes the region below it to not become collapsible. If you could confirm that this happens on your end with the code I have attached to this post, that would be very helpful as well.

Applications Engineering
National Instruments
0 Kudos
Message 2 of 4
(2,290 Views)

Hello Sailesh,

I have tried your file and found the following:

If I simply open it in an extra tab within an existing project, it does not show the collapse/expand icons in the editor.

However, the menu command collapse all / expand all works - and after applying this menu command the collapse/expand icons are displayed...

0 Kudos
Message 3 of 4
(2,282 Views)

Hi,

unfortunately I have the same behavior of missing Region markers in my CVI editor.

Most of my regions can be collapsed without issues, but some of them not.

At the Moment, i have not that much lines in these faulty regions, sometimes 200 to 500 lines.

Both REGION Statements are set correctly, that can you see on the attached pictures.

 

If i use the "Collapse All / Expand All" command in CVI, all missing markers are added.

Sometimes CVI adds these markers, if i edit the "REGION START" or "REGION END" line.

But that is absolutely not reproducible.

 

I am using LabWindows CVI 2017 in V17.0.0 (295) 

Download All
0 Kudos
Message 4 of 4
(2,150 Views)