LabWindows/CVI Idea Exchange

Community Browser
cancel
Showing results forย 
Search instead forย 
Did you mean:ย 
Post an idea

At present, autoscaling works with respect to the full provided data set, i.e. if all data are shown on the graph.

 

If say the X axis is set to manual scaling such that only a subset of all data is plotted, autoscaling of the Y axis still considers all data even if they are not shown, see the discussion here.

 

Hence it is suggested to provide an additional auto scaling mode which considers only the data actually visible on the graph, say VAL_AUTOSCALE_VISIBLE_DATA, complementing the current VAL_AUTOSCALE which actually is a VAL_AUTOSCALE_ALL_DATA

I want to be able to do the following:

 

  1. Right-click on a control on my user interface and select โ€œAdd Event Case to Control Callbackโ€ (if a callback function already exists)
  2. CVI brings up a dialog similar to what you see at Code>>Preferences>>Default Events to select an event for that control
  3. Check the box for one or more events for that control, click OK, then
  4. Have CVI find the existing control callback function and add a case to the switch statement for each event I checked

If you havenโ€™t written any code in the callback already, you can just change the default events and re-generate (replace) the control callback.

 

However, if you have already written code for one event case, the only way I can find to add an event case is to do it manually. I go to Code>>Preferences>>Default Events or use the Operate tool to look for the constant name of the event that I am interested in, then I go back to my code and manually type out โ€œcase EVENT_CONSTANT_NAME: break;โ€ with the name of the event and hope I remember it correctly and spell it right.

 

CVI is all about minimizing user errors and reducing development time by, you know, not making you type things out yourself, so I think this functionality would be a useful addition.

As of CVI2013 data tooltips and variable view do some kind of automatic rounding but based on 15 digits only... This prevents tracking numeric / rounding issues. Unfortunately, no possibility exists to show the full precision of doubles... Phrased more drastically one you cannot use CVI to debug numeric issues...

 

So I suggest to urgently add

 

 

  • as a minimum version the possibility to show true numbers, not rounded numbers, allowing true debugging
  • as a more general version the possibility to adjust the precision of displayed numeric values

                 

 

Hello,

 

I have a table with several columns. Let's assume I want to modify properties of column 5. It would be nice if when clicking on column 5 in the UI editor this column would be preselected. Right now, the table editor opens and one has to manually select a column...

 

Thanks

Add support for Show Completion to detect when a user is typing in the name of an include file, within the #include brackets or quotes, and display suggestions of headers.

 

The suggested headers can be anything from the supported library headers or user include paths.

 

ShowCompletionsHeaders.png

Problem:
The Find dialog currently doesn't store its text search settings (e.g. Case sensitive, Whole word) if the User cancels the dialog.

 

Details:

The Find dialog only stores its text search settings if the user explicitly performs a file search. The disadvantage of this behaviour, is that the user has to reconfigure his search settings after cancelling the dialog. Users may sometimes open the Find dialog, configure some search settings and then (probably accidentally) cancel the dialog, but then open the dialog again to perform the actual search. This way the previous search settings are reset and lost.

 

Suggestion:

I suggest that the search setting should be stored somehow in the CVI ADE, such that the search settings persist in the text editor, despite of the user cancelling the Find dialog.

I also think that this should apply for other text search dialogs (like, Find in Files, Replace, Replace in Files). This behaviour of a text search dialog is particularly accepted by other mainstream text editors and IDEs.

 

Advantages:

  1. Search settings are stored even if the user cancels the Find dialog.
  2. User doesn't have to explicitly invoke a find operation through the Find dialog, in order to have search settings (mainly the 'Case sensitive' setting) influence the Quick Search (Ctrl + Q) functionality. This is by far, the most helpful use case for this change. It's quite cumbersome to always have to performs a Find operation through a find dialog, in order to change the case sensitivity of the Quick Search feature, particularly because the find operation takes extra steps and causes distraction (displays the Find Results window).

I have two suggestions for minor improvements of the statusbar, see the figure below:

 

1) If the active window is a source code window I would like to see the name of the function the current line belongs to. If your function is longer, the name will not be visible on the screen and thus one has to scroll up to find out...

 

2) I'd suggest to have a fixed width of the Build Configuration field - right now the width changes e.g. between debug and debug32 and thus all other fields jump left- or rightwards...

 

Thanks!newstatusbar.png

Hello,

 

I have two suggestions concerning this menu:

 

First, I'd like to have the option NOT to show the Build window if there is no error. Right now, I edit code, test run the code, and then have to close the Build Output window every time because it uses place (if you use a split screen it does make a difference...). Yes, I could change the height of the Build Output window, but then if there is an error I don't see it...

 

Suggestion: Add an option 'Always show Build output' or similar.

 

Second, make the checkmarks in the window menu modal and consistent

 

what does a checkmark in the Window menu of CVI mean? At present, not much...

 

If you select 'Build Output', this menu item shows a checkmark and the Build output window is displayed - sounds reasonable.

If one then selects 'Source Code Browser', the checkmark moves on to the new selection, although both windows are displayed there is only one checkmark. So no checkmark does not imply that there is no window...

Selecting a checked menu item does not undo the action, the checkmark remains and the window, too. I find this, hm, special... and would like to have it changed to a modal operation.

When you place a splitter control on a panel with several controls and want to attach a few of them to the splitter, you can define for each of them whether the splitter moves or resizes the control ("attachment mode"). At present, however, this must be made individually control by control, which is time wasting if you have a bunch of similar controls to attach and define.

 

I suggest the splitter control is added the ability to select more controls and set for all of them the attachment mode in a single pass. Limiting this possibility to similar controls (e.g. only numerics or tables selected) can be accepted if this simplifies checks the editor does in this operation.

 

(this suggestion refers to CVI up to 2012SP1, I cannot check it for more recent releases)

While defining attachment mode for controls attached to a splitter we face a very strange situation. In this image you can see on the right the aspect of the window with one control selected in "Controls on the splitter" window in Attach/Detach Controls dialog. On the right the same dialog when you click on Attachment mode control:

 

SplitterCtrlAssignment.png

 

Now, there are two strange effects:

  1. Attachment mode control is being operated while dimmed Smiley Surprised
  2. If you happen to miss Attachment mode ring, you need to select again the original control in order to have the ring enabled, which is boring and time-wasting

I suggest that at least that ring is not disabled when clicking on it or clicking away from "Controls on the splitter" box.

 

(this suggestion refers to CVI up to 2012SP1, I cannot check it for more recent releases)

As discussed here and here, CVI does not re-open workspace files in the order they were when CVI was closed; I am referring to confined workspace, not freely floating windows.

 

As a result, starting CVI one first has to locate all the files, where did the include file go...? If you happen to have some more tabs this is a waste of time.

 

Also, as Roberto mentioned, you can not easily use the short cut keys Ctrl-1 etc. because of the changing assignment.

 

So, in short, I am asking to improve this behavior and maintain the tab order of CVI workspace files, that is, re-arrange/re-open the tabs in the order they were when CVI was closed.

 

Thanks!

The  shortcut "Ctrl+Space" is for changing the input method in the some system.

  

Even we can change the shutcut, this function is so often to use.

 

The ideal is to make it like the way in some common source editor: when typing from any space position, the completion shows automatically.

 

This could be an option, to toggle on or off in  Edit>> Auto Completion menu item .

While it is possible to programmatically add a menubar to a tab page with LoadMenuBar, it is not possible to do that in the UIR editor.

 

Sometimes I use a tab control to display different scenarios to the user hiding tabs so that he's not aware of the pages not shown: this permits to have a single panel with all elements properly placed and designed on the different pages and programmatically choose which page to display depending on operating conditions or other characteristics. In such a case the tab page behaves like a "normal" panel, but while you can have a standard child panel with its own menubar, you cannot add one to a tab page other than programmatically.

 

It would be a handy to be able to add a menubar to tab pages too in the editor.

While it is possible to add, remove and replace files in a CVI project it is not possible to rename or duplicate a file.

 

This is useful for example if a large source code file shall be split to speed up compilation. Although this file operation could be done outside of CVI associated tags would be lost.

 

A workaround has been offered here but a more elegant and simple solution would be welcome. Hence I suggest to provide two more commands to add and duplicate a file including its associated tags and breakpoints...

 

Thanks.

Sorry for the long message.

My proposals are at the very end of this post

In order to understand the rationales I propose 2 experiments

 

Experiment #1:

In C:\Users\Public\Documents\National Instruments\CVI2013\samples\userint
Open 2yaxis project

 

Here is the code of interrest (lines 131-145):

 

int CVICALLBACK ScaleIt (int panel, int control, int event, void *callbackData,
                         int eventData1, int eventData2)
{
    int val;
    
    if (event == EVENT_COMMIT)
        {
        GetCtrlVal (panel, control, &val);
        SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_ACTIVE_YAXIS,
                          VAL_RIGHT_YAXIS);   
        SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_YMAP_MODE, val);
        SetActiveCtrl (panel, PANEL_GRAPH);
        }
    return 0;
}

 

Set a break point line 141 (second SetCtrlAttribute())
Then comment line 141 with 2 "/" at the beginning of the line of code
Debug the project (SHIFT+F5)
Before the code start, the breakpoint move "automatically" from line 141 to 142

 

Note : This is "OK". Indeed line 141 is no longer executable so it seems reasonable to move the breakpoint to the next valid line of code.

 

When the UIR appears, click on the scale control
Once in the editor, stop the debug session

 

At this point you should see the breakpoint moving automatically from line 142 to line 141

 

Question : Why? While the breakpoint on line 142 is enable and valid , why does the breakpoint "remember" it comes from
line 141 and then "decide" do go back on this line?


I believe it has to do with the fact that CVI try to set the environment back to the state it was before debugging the code.
IMHO this is weird.

Indeed, at the end we have a source code with a breakpoint set on a commented line.

What is the value for the user?

 

 

Experiment #2 :
If you run the same experiment but, this time, starting with a breakpoint and a comment on line 142 (last SetActiveCtrl() function call)
then the breakpoint move automatically from line 142 to line 144 (return statement)

 

The issue now is that the code stop on the return statement quite often and not only when the EVENT_COMMIT is managed

 

Based on previous experiments I would like to suggest the following 

 

Plan A :


- During code edition, commenting a line of code which have a breakpoint CVI should disable the breakpoint (grey diamond). This provide visual information to the user.
- CVI should not try to find a new line of code where to set an active breakpoint
- Uncommenting a line which had a breakpoint CVI should NOT enable the breakpoint for the user. The breakpoint should stay grey. A single click on the grey diamond should enable the breakpoint (see another proposal I made about breakpoints)

 


Plan B :


- If, before execution, one breakpoint is found on a commented line
- Disable the breakpoint on the commented line (grey diamond). This provide visual information to the user.
- Try to set an new active breakpoint to the statement right after the current line of code if and only if :

a - the statement belongs to the same current block ( {.....} )

b - the condition (if any) is still valid on the selected line of code (this is already done today by CVI)

- If this is not possible, try to set an new active breakpoint to the statement right before the current line of code if and only if :

a - the statement belongs to the same current block ( {.....} )

b - the condition (if any) is still valid on the selected line of code

- Once set, even after the debugging session ends, the new active breakpoint remains active and in place

 

 

I vote for Plan B

Best regards, Philippe

Basically the API should provide

GetCVIDir(char **path);                                    // return an array of paths to the different CVI versions installed

GetCVIFilesTemplateDir(const char *path2CVI, char *path);  // if path2CVI is NULL, path target the most recent vesion of CVI installed

GetCVIProjectTemplateDir(const char *path2CVI, char *path);

GetCVISampleDir(const char *pathchar *path);

...

 

It is always possible to write such functions but for example, for the samples directory this is a pain because you need to resolve the CVI Samples.lnk file using IShellLink interface, OLE32 etc.

Best regards, Philippe

First of all : I LOVE the Format File and Format Selection and many thanks for the existing options in the dialog box (pointer for example)

 

Here is what I propose :

 

1 - "Function calls on single line" check box in the Miscellenaous section of the dialog box so that :

 

int CVICALLBACK ScaleIt (int panel, int control, int event, void *callbackData,
                         int eventData1, int eventData2)
{
    int val;
    
    if (event == EVENT_COMMIT)
        {
        GetCtrlVal (panel, control, &val);
        SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_ACTIVE_YAXIS,
                          VAL_RIGHT_YAXIS);   
        SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_YMAP_MODE, val);
        SetActiveCtrl (panel, PANEL_GRAPH);
        }
    return 0;
}

 The code above comes from ..\CVI2013\samples\userint\2yaxis.prj

 

Is transformed in :

 

int CVICALLBACK ScaleIt (int panel, int control, int event, void *callbackData, int eventData1, int eventData2)
{
    int val;
    
    if (event == EVENT_COMMIT)
        {
        GetCtrlVal (panel, control, &val);
        SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_ACTIVE_YAXIS, VAL_RIGHT_YAXIS);   
        SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_YMAP_MODE, val);
        SetActiveCtrl (panel, PANEL_GRAPH);
        }
    return 0;
}

 

Please note this apply not only to the SetCtrlAttribute() function call but also to the ScaleIt() function itself (very first line)
A long time ago it was OK to restrict ourselves to 80 chars per line but today I feel more confortable with statements on one line

 

2 - "Insert empty line before first statement in function definition" check box in the Miscellenaous section of the dialog box
Especially usefull when you use the Java Formating Option where the '{' is at the end of the line


With the previous sample code :

 

int CVICALLBACK ScaleIt (int panel, int control, int event, void *callbackData, int eventData1, int eventData2)
{
    int val;
    
    if (event == EVENT_COMMIT)
        {
        GetCtrlVal (panel, control, &val);
        SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_ACTIVE_YAXIS, VAL_RIGHT_YAXIS);   
        SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_YMAP_MODE, val);
        SetActiveCtrl (panel, PANEL_GRAPH);
        }
    return 0;
}

 

The formated source (Java) should be :

 

int CVICALLBACK ScaleIt (int panel, int control, int event, void *callbackData, int eventData1, int eventData2) {
  
  int val;

  if (event == EVENT_COMMIT) {
    GetCtrlVal (panel, control, &val);
    SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_ACTIVE_YAXIS, VAL_RIGHT_YAXIS);
    SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_YMAP_MODE, val);
    SetActiveCtrl (panel, PANEL_GRAPH);
  }
  return 0;
}

 

Instead of : 

 

int CVICALLBACK ScaleIt (int panel, int control, int event, void *callbackData, int eventData1, int eventData2) {
  int val;

  if (event == EVENT_COMMIT) {
    GetCtrlVal (panel, control, &val);
    SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_ACTIVE_YAXIS, VAL_RIGHT_YAXIS);
    SetCtrlAttribute (panel, PANEL_GRAPH, ATTR_YMAP_MODE, val);
    SetActiveCtrl (panel, PANEL_GRAPH);
  }
  return 0;
}

 

Pay attention to the "int val;" declaration with one spacing line in the first code and no spacing line in the second one.

 

Best regards, Philippe

 

To make a long story short : Breakpoints should be a kind of "3 or 4 states round-robin object" with some sort of memory regarding the condition (if any)

 

Let me explain...

 

Let start on one line with an empty margin
first click  : set breakpoint     - red diamond
second click : disable breakpoint - grey diamond
third click  : delete breakpoint  - empty margin

 

At this point, when the user click again and again in the margin he can see the red, grey and empty margin cyclically. Yes, 3 clicks are now needed in order to recover an empty margin (instead of 2 actually)


The behavior above ehance the existing behavior. Indeed, it gives more option to the user (disable breakpoint) without changing the way of working. In addition, it help users to discover breakpoints can be disable.

 

Now let's look the case where, at one point the user set a condition for the breakpoint

 

Again, let's start on one line with an empty margin
first click  : set breakpoint     - red diamond
right click  : edit breakpoint    - yellow rectangle (should be yellow diamond, small change in the display)
second click : disable breakpoint - grey diamond (instead of grey rectangle, this is a disable breakpoint)
third click  : delete breakpoint  - empty margin

 

Then, when the user click again and again in the margin he can see the red, yellow, grey diamonds and empty margin cyclically. 
Please note that the latest condition of the conditional breakpoint is set/recall automatically when the yellow diamond appears (memory effect). 

 

Again, the behavior above ehance the existing behavior. The key point is that you "do not loose" your condtionnal breakpoint when you click on it. I know it is not true since the breakpoint is still in the list of breakpoints but this is a frustrating experience when you click on a yellow recetangle and whe you see it "disapear".

Last but not least, overing a yellow diamond (rectangle) should display the condition in a tooltips (passcount = x - condition is : "sdfsdfsf"). I know it has been already propose and it is under consideration.

 

Best regards, Philippe 

It would be great if NI could provide standard translations of the NI runtime message file msgrte.txt in commonly-used languages.

 

Whilst we can get translations done ourselves, it is normally done by translators who have little knowledge of the runtime context so the quality is rather variable; also, I get the feeling that we are duplicating effort that may have been already spent elsewhere.

 

If it helps, I for one would be willing to pay for a decent translation.

CTRL+Q should highlight all instances of the results in the editor

Same thing with CTRL+F

This is similar to Notepad++ for example

 

I find the ALT+UP ARROW and ALT+DOWN ARROW of Visual Studio 2013 quite useful (move selected lines)

 

Please, implement CTRL + L to delete a line

I know the short cut is already owned by "go to line" but my current macro is not that good ๐Ÿ˜ž

 

It seems macros are not working in the editor while debugging a code.

Could be usefull.

Will be mandatory if one day the "Comment multiple lines" is implemeted using a macro ๐Ÿ™‚

 

Best regards, Philippe