|
|
|
SftDirectoryFolder.Can Method |
Tests whether the specified action is supported by the file/folder.
Syntax
VB.NET |
Supported = object.Can(ByVal Action As String) As Boolean |
||
VB |
Supported = object.Can(ByVal Action As String) As Boolean |
||
C#.NET |
bool Supported = object.Can(string Action); |
||
VC++ |
VARIANT_BOOL Supported = object->Can(_bstr_t Action); |
||
C |
HRESULT object->raw_Can(BSTR Action, VARIANT_BOOL* Supported); |
||
Delphi |
Supported := object.Can(Action : WideString) : WordBool; |
object
A SftDirectoryFolder object.
Action
A string defining the action to be tested. The string is case-sensitive and must be entered as shown here, without leading or trailing blanks. Some of the standard Action strings (implemented by Windows and Shell extensions) are:
Action |
Description |
copy |
Copy a file/folder to the clipboard |
open |
Execute program or open a file |
explore |
Open a file/folder in a new window |
cut |
Copy a file/folder to the clipboard and remove it |
delete |
Remove a file/folder |
link |
Create a shortcut |
move |
Move a file/folder to another location |
rename |
Rename a file/folder |
droptarget |
Tests if a file/folder is a valid target for a drag & drop operation |
paste |
Copy the clipboard contents to the specified location |
properties |
Display file/folder properties |
NewFolder |
Create a new folder |
Supported
On return, specifies whether the specified action is supported by the file/folder.
Supported |
Description |
True |
The file/folder supports the specified action. |
False |
The file/folder doesn't support the specified action. |
Comments
The Can method tests whether the specified action is supported by the file/folder.
Strings provided as Action parameter are Windows operating system specific and may be implemented by Shell extensions. Action parameters are not processed or implemented by SftDirectory, they are simply passed to the Windows Shell or Shell extensions.
The action can be executed using the Folder.Do method.
The Folder.Can method can be used to test one particular folder only. The control's Can method tests all currently selected folders.