IShellLinkA::SetArguments method (shobjidl_core.h)
Sets the command-line arguments for a Shell link object.
Syntax
HRESULT SetArguments(
[in] LPCSTR pszArgs
);
Parameters
[in] pszArgs
Type: LPCTSTR
A pointer to a buffer that contains the new command-line arguments. In the case of a Unicode string, there is no limitation on maximum string length. In the case of an ANSI string, the maximum length of the returned string varies depending on the version of Windows—MAX_PATH prior to Windows 2000 and INFOTIPSIZE (defined in Commctrl.h) in Windows 2000 and later.
Return value
Type: HRESULT
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
Remarks
This method is useful when creating a link to an application that takes special flags as arguments, such as a compiler.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | shobjidl_core.h |
DLL | Shell32.dll (version 4.0 or later) |
See also
IShellLinkA
IShellLinkW