Populate Table toolbar

<< Click to Display Table of Contents >>

Navigation:  Programming > User Interface > Toolbar > Ribbon Applications > TMS Office 2010 >

Populate Table toolbar

To create a table menu You can either use the standard action WPDefAct.aTbl_CreateTable or a TAdvOfficeTableSelector. If You use TAdvOfficeTableSelector, You need this code to create a table:

 

procedure TWPEditor.AdvOfficeTableSelector1SelectTableSize(Sender: TObject;

 Columns, Rows: Integer);

begin

  WPRichText1.TableAdd(Columns, Rows, [wptblActivateBorders]);

end;

 

If you use WPDefAct.aTbl_CreateTable You only need to place a button and assign the action.

 

tabletools

 

We also add a button toolbar by using actions from WPDefAct. We set the property Rounded to true and the property Position to bpLeft, bpMiddle ... and bpRight to create the grouped look. All buttons which can also display a state (active/inactive) the property Style must be to to bsCheck.

 

clip0188