Admin Production ni-theme
Current Publication

SetTextCtrlHeight

LabWindows/CVI

SetTextCtrlHeight

int SetTextCtrlHeight (int panelHandle, int controlID, int width);

Purpose

Sizes the height of the specified text box or text message control based on the width parameter and the text content in word wrap mode.

Note Note  This function changes the wrap mode of the text box to word wrap mode.

You can use this function to size the height of a panel that contains text at run time based on a font that may change because of system settings, such as large fonts or normal font size.

Supported Controls

You can use SetTextCtrlHeight with the following controls:

Parameters

Input
Name Type Description
panelHandle int Specifier for a particular panel that is currently in memory. You can obtain this handle from functions such as LoadPanel and NewPanel.
controlID int The defined constant, located in the .uir header file, that you assigned to the control in the User Interface Editor, or the ID returned by functions such as NewCtrl and DuplicateCtrl.
width int The width of the text box or text message. Pass -1 to leave the width unchanged.

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: User Interface Library

Include file: userint.h

LabWindows/CVI compatibility: LabWindows/CVI 9.0 and later