bOk = MTblDefineButtonCell( hWndCol, nRow, bShow, nWidth, sText, nImage, nFlags )

Depreciated, please use MTblDefineItemButton instead.

Defines a cell as a button cell. That means, if the cell gets the focus, a right aligned button like this is shown:

If the user clicks the button, the message MTM_BtnClick is sent to the table.

Parameters
hWndCol
Window Handle: Handle of the column

nRow
Number: Number of the row

bShow
Boolean: TRUE = button is visible, FALSE = button is hidden and the button definition of the column is used

nWidth
Number: Width of the button in pixels. If you specify -1, the witdh of the button is adapted to the button's text and/or image.

sText
String: Button text

nImage
Number: Handle of the image to display. Specify 0 to display no image.

nFlags
Number: Any combination of button flags

Return
Boolean: TRUE if successful or FALSE if an error occurs

Example
In this example a cell button is defined as follows: Visible, dynamic width, text "...", no image, and the font is shared:

Call MTblDefineButtonCell( hWndCol, nRow, TRUE, -1, "...", 0, MTBL_BTN_SHARE_FONT )

Remarks
Popup edit columns are not supported.
For nImage you have to use handles returned by M!Image functions. Handles returned by VicPicLoad or by API functions can't be used.

See also
Buttons

Created with the Personal Edition of HelpNDoc: What is a Help Authoring tool?