Specifies and stores the proposed name of the file.
HRESULT SetFileName( LPCWSTR pszFileName );
A pointer to a string that contains the file name.
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code, including the following.
||The pszFileName value is is set to NULL, points to an empty string, or points to a file name longer than MAX_PATH.|
||The file name cannot be stored.|
No path information should be included at pszFileName, just the file's name.
IAttachmentExecute::SetFileName can be used by the calling application to check the validity of the file name before copying the file locally. The file name is checked for name collisions against other files stored at the local path location.
IAttachmentExecute::SetFileName is optional.
|Minimum supported client||Windows XP with SP2 [desktop apps only]|
|Minimum supported server||Windows Server 2003 [desktop apps only]|
|Header||shobjidl_core.h (include Shobjidl.h)|
|DLL||Shdocvw.dll (version 6.0 or later)|