RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TMenuItem.InsertNewLineAfter Method

Inserts a separator bar after a specified item from the Items property array.

Pascal
function InsertNewLineAfter(AItem: TMenuItem): Integer;
C++
__fastcall int InsertNewLineAfter(TMenuItem AItem);

Use InsertNewLineAfter to insert a separator bar after the menu item specified by AItem. If AItem is not an item in the Items property array, InsertNewLineAfter raises an exception. 

InsertNewLineAfter returns the index of the newly inserted separator item in the Items property array.

Tip: When inserting separator bars at runtime, it is a good idea to set AutoLineReduction to true so that superfluous separators can be automatically removed.
 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!