Share via


SetRequestUrl Method

The SetRequestUrl method sets the request URL format for subscriptions.

Syntax
Sub SetRequestUrl(bstrRequestUrl As String)[C++]
HRESULT SetRequestUrl(BSTR bstrRequestUrl);
Parameters

[Visual Basic]

  • bstrRequestUrl
    String that contains the format in which the URL for the subscription and associated notifications should be rendered in subscription notices. For example, if the value of this string is "http://MyServer/", and you are subscribing to "MyDoc.doc" in the document library, the subscription URL will be rendered as "http://MyServer/MyWorkspace/Documents/MySub.doc" in the Extensible Markup Language (XML) results returned by the GetResults method. If the bstrRequestUrl parameter is a fully qualified domain name (FQDN), such as "http://www.microsoft.com/", the subscription URL for the same subscription will be rendered as "http://www.microsoft.com/MyWorkspace/Documents/MySub.doc" by the GetResults method.
Return Values

None.

Error Values

For a list of errors returned by SharePoint Portal Server subscription management objects, see Error Messages.

[C++]

  • bstrRequestUrl
    [in] BSTR that contains the format in which the URL for the subscription and associated notifications should be rendered in subscription notices. For example, if the value of this string is "http://MyServer/", and you are subscribing to "MyDoc.doc" in the document library, the subscription URL will be rendered as "http://MyServer/MyWorkspace/Documents/MySub.doc" in the XML results returned by the GetResults method. If the bstrRequestUrl parameter is a FQDN, such as "http://www.microsoft.com/", the subscription URL for the same subscription will be rendered as "http://www.microsoft.com/MyWorkspace/Documents/MySub.doc" by the GetResults method.
Return Values

For a list of errors returned by SharePoint Portal Server subscription management objects, see Error Messages.

Remarks

No validation is performed on bstrRequestUrl. Call this method before the GetResults method if you want the subscription URLs to be rendered by using the FQDN of the server. If SetRequestUrl is not called, the URLs are rendered by using the network basic input/output system (NetBIOS) name of the server. This setting is only valid while the SubscriptionResultManager object is persistent.

Example

The following code example in Visual Basic demonstrates how to set the request URL for subscription in a workspace.

Dim oSubMgr
Set oSubMgr = CreateObject("PKM.SubscriptionManager")

Dim strWorkspace
strWorkspace = "MyWorkspace"

Dim oResMgr
Set oResMgr= oSubMgr.GetResultManager(strWorkspace)
oResMgr.SetRequestUrl "http://www.microsoft.com"