LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

I am having problems with the development environment screen/panel sizes running on Win2000

Once a screen/panel is opened up it does not include all of the text or buttons. Manually you can often stretch the panel (eg. function panels) but once the panel is closed then the size is not remembered. Even on pop-up of errors, the selction of buttons is not always visible and you do not get the choice of choosing any other than hot key. I am using a Matrox G400 video card (dual head).
0 Kudos
Message 1 of 4
(3,242 Views)
Hello Murray,
Many popups such as function panels and debug warning/error dialogs can be resized at runtime, but they do not save or retain their sizes. LabWindows/CVI inherits many font and display properties from the system's Display settings, possibly you have a large font chosen that is pushing other buttons and data out of the normal popup boundaries? I would recommend experimenting with your Display settings to see if they effect this behavior. Also, LabWindows/CVI 5.5.x and higher is required for official multi-monitor support. If you have CVI 5.5.x or higher and continue to have problems, please contact us at http://www.ni.com/ask and forward us screenshot(s) with additional details on the behavior so that we may assist you.

Jeremiah Cox
Applications Engi
neer
National Instruments
http://www.ni.com/ask
0 Kudos
Message 2 of 4
(3,242 Views)
I should have also mentioned that in your case, you would
need to save and restore the panel's ATTR_WIDTH and
ATTR_HEIGHT attributes instead of, or in addition to,
the ATTR_TOP and ATTR_LEFT.
0 Kudos
Message 4 of 4
(3,242 Views)
I solved a similar problem by acquiring the current screen position
attributes when the program exits and saving them in hidden
numeric controls in a panel state file. Then when the program
is launched the next time, the previous panel position can be
restored programmatically from the numeric control values.

For example, add this to the end of your main() function:

// Get current screen position attributes of panels and save them as
// numeric controls so they can be recalled from the panel state the
// next time the program is launched.
GetPanelAttribute(panelGP, ATTR_TOP, &nGPTop);
GetPanelAttribute(panelGP, ATTR_LEFT, &nGPLeft);
SetCtrlVal(panelGP, GP_TOP, nGPTop);
SetCtrlVal(panelGP, GP_LEFT, nGPLeft);
// Save the current control settings to the panel state file
S
avePanelState(panelGP, szPanelStateFileName, 0);

And add this to the start of your main() function:

// Restore panel to its previous position.
RecallPanelState(panelGP, szPanelStateFileName, 0);
SetPanelAttribute(panelGP, ATTR_TOP, nGPTop);
SetPanelAttribute(panelGP, ATTR_LEFT, nGPLeft);

It would be a real convenience if CVI had an option to
automatically save and restore panel positions in the panel
state file but at least it has hooks for you to do it yourself.

"Murray" wrote in message
news:5065000000080000005F2A0000-999158726000@exchange.ni.com...
> Once a screen/panel is opened up it does not include all of the text
> or buttons. Manually you can often stretch the panel (eg. function
> panels) but once the panel is closed then the size is not remembered.
> Even on pop-up of errors, the selction of buttons is not always
> visible and you do not get the choice of choosing any other than hot
> key. I am using a Matrox G400 video card (dual head).
0 Kudos
Message 3 of 4
(3,242 Views)