Click or drag to resize

ShellUtilitiesExtractMenu Method (String, Boolean)

Extracts all menu items from a shell item's context menu.

Namespace:  ShellBoost.Core.Utilities
Assembly:  ShellBoost.Core (in ShellBoost.Core.dll) Version: 1.8.3.0
Syntax
C#
public static IReadOnlyList<ShellMenuItem> ExtractMenu(
	string path,
	bool throwOnError = true
)

Parameters

path
Type: SystemString
The shell item's path.
throwOnError (Optional)
Type: SystemBoolean
true to throw error; otherwise false.

Return Value

Type: IReadOnlyListShellMenuItem
A list of ShellMenuItem instances.
Exceptions
ExceptionCondition
ArgumentExceptionpath is null.
Remarks
This method behavior depends on many contextual parameters such as the process bitness (32 or 64 bit), the type of process (Console vs Windows), or the the current thread's COM apartment state (STA vs MTA, etc.). It also depends on how dynamic context menu handlers choose to add or not menu items.
See Also