URLAssociationDialogA function (intshcut.h)
Invokes the unregistered URL protocol dialog box. This dialog box allows the user to select an application to associate with a previously unknown protocol.
Syntax
INTSHCUTAPI HRESULT URLAssociationDialogA(
HWND hwndParent,
DWORD dwInFlags,
PCSTR pcszFile,
PCSTR pcszURL,
[out] PSTR pszAppBuf,
UINT ucAppBufLen
);
Parameters
hwndParent
Type: HWND
A handle to the parent window.
dwInFlags
Type: DWORD
The bit flags that specify the behavior of the function. This value can be a combination of the following:
URLASSOCDLG_FL_USE_DEFAULT_NAME
Use the default file name (that is, "Internet Shortcut").
URLASSOCDLG_FL_REGISTER_ASSOC
Register the selected application as the handler for the protocol specified in pcszURL. The application is registered only if this flag is set and the user indicates that a persistent association is desired.
pcszFile
Type: PTCSTR
The address of a constant zero-terminated string that contains the file name to associate with the URLs protocol.
pcszURL
Type: PTCSTR
The address of a constant zero-terminated string that contains the URL with an unknown protocol.
[out] pszAppBuf
Type: PTSTR
The address of a buffer that receives the path of the application specified by the user.
ucAppBufLen
Type: UINT
The size of pszAppBuf, in characters.
Return value
Type: HRESULT
Remarks
Note
The intshcut.h header defines URLAssociationDialog as an alias that automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that is not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | intshcut.h |
DLL | Url.dll |