LabWindows/CVI

Toolbar_LoadStates

int Toolbar_LoadStates (const char *sourceFile, ...);

Purpose

Loads all the user-configurable states of all of the toolbars on all of the panels you specify and also loads any floating toolbars. Pass a list of panel IDs terminated with a 0. The order of these panels corresponds to that of the panels saved in the call to Toolbar_SaveStates, as is shown by the following example:

Toolbar_LoadStates ("tb_state.ini", hMainPanel, hOtherPanel, 0);

Parameters

Input
Name Type Description
sourceFile const char * The source .ini file, previously generated by Toolbar_SaveStates, from which the toolbar states will be loaded.
panelList ... A 0-terminated list of panels. LabWindows/CVI restores the state of the toolbars to these panels. The order matches the order of panels used when you call Toolbar_SaveStates.

Return Value

Name Type Description
status int Return value indicating whether the function was successful. A negative number indicates that an error occurred.

Additional Information

Library: Toolbar

Include file: custctrl\toolbar.h

LabWindows/CVI compatibility: LabWindows/CVI 8.0 and later

Example

Refer to userint\custctrl\toolbar\tooldemo.cws for an example of using the Toolbar_LoadStates function.