Contents Previous Page Next Page
HlinkSimpleNavigateToString

This helper function should be used by all application, documents, and objects that have simple navigation needs. This single function call that will ôdo the right thingö depending on whether the navigation is originating from within a hyperlink frame or within a hyperlink-unaware application.

HlinkSimpleNavigateToString(

    LPCWSTR 
szTarget,                       //String to be resolved into targetÆs moniker                 
                                                                                                          
    LPCWSTR szLocation,                     //Optional string representing location within target         
                                                                                                          
    LPCWSTR szTargetFrameName,              //Optional string naming the target frame                     
                                                                                                          
    LPCWSTR szAdditionalParams,             //Additional parameters                                       
                                                                                                          
    IUnknown * pUnk,                        //IUnknown interface of initiating document or object         
                                                                                                          
    DWORD grfHLNF,                          //Navigation flags                                            
                                                                                                          
    IBindCtx * pbc,                         //Bind context object                                         
                                                                                                          
    IBindStatusCallback * pbsc,             //Bind status callback object                                 
                                                                                                          
    DWORD dwReserved                        //Reserved for future use                                     
                                                                                                          
   );                                                                                                     
                                                                                                          

Parameters

szTarget

[in] String which helps identify the hyperlink target. This string is resolved into a moniker for underlying binding operations via MkParseDisplayNameEx. If NULL, then the navigation is within a document. This parameter is required.

szLocation

[in] Optional string representing the location within the hyperlink target for the new hyperlink.

szTargetFrameName

[in] Optional string naming the target frame for the hyperlink navigation. This argument only affects navigation within a document container that understands frame-sets.

szAdditionalParams

[in] Additional string parameters for the hyperlink navigation (currently ignored). IHlink::SetAdditionalParams and IHlink::GetAdditionalParams describe the format.

pUnk

[in] The IUnknown pointer to the document or object that is initiating the hyperlink. If NULL, it is assumed the hyperlink originates from an OLE-unaware application.

grfHLNF

[in] Value taken from the HLNF enumeration.

pbc

[in] IBindCtx interface pointer to the bind context object to use for any moniker binding performed during the navigation. May not be NULL.

pbsc

[in] IBindStatusCallback interface pointer to the bind-status-callback object to use for any asynchronous moniker binding performed during the navigation. May be NULL, in which case the caller is not interested in progress notification, cancellation, pausing, or low-level binding information.

dwReserved

[in] Reserved for future use, must be set to NULL.

Return Values

S_OK

A hyperlink knowing the name of its target has navigated to it successfully.

This function can also return any value returned by IHlink::Navigate.

See Also

HlinkNavigate, HlinkNavigateToStringReference, HlinkSimpleNavigateToMoniker, HLNF, IHlink::Navigate