Export (0) Print
Expand All

IShellLink::SetArguments method

Sets the command-line arguments for a Shell link object.

Syntax


HRESULT SetArguments(
  [in] LPCTSTR pszArgs
);

Parameters

pszArgs [in]

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

Minimum supported client

Windows XP [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Shobjidl.h

IDL

Shobjidl.idl

DLL

Shell32.dll (version 4.0 or later)

See also

IShellLink
IShellLink::GetArguments

 

 

Community Additions

ADD
Show:
© 2015 Microsoft