ShellBrowser Delphi Components Documentation
ContentsIndexHome
PreviousUpNext
ShellBrowser.TShellBrowser.ShowContextMenu

Shows the context menu for files or folders as submenu of an existing menu item.

Syntax
Pascal
function ShowContextMenu(const Pos: TPoint; ShellMenuAnchor: TMenuItem; pBeforeCommand: TBeforeCommandFunc = nil): String; overload;
Parameters 
Description 
const Pos: TPoint 
Position on the screen at which the context menu should appear. 
ShellMenuAnchor: TMenuItem 
A menu item after that the Shell context menu should be inserted. If you want to show a the Shell context menu as submenu, add a signle menu item as submenu and set its Visible property to False. You may then use this menu item as anchor for the Shell context menu.  
pBeforeCommand: TBeforeCommandFunc = nil 
An optional callback that will be called before the chosen command is executed. 

String: the shell command that was executed, an empty string if no shell comand was executed.