IWMSPublishingPoint.Path (Visual Basic .NET)

The Path property specifies and retrieves the path to the publishing point content.

IWMSPublishingPoint.Path = String
String = IWMSPublishingPoint.Path

Property Value

A String containing the path.

If this property fails, it returns an error number.

Number

Description

0x8007000E

There is insufficient memory to complete the function.

0xC00D002BL

The path for a publishing point cannot be changed while the publishing point is running.

0xC00D145AL

The publishing point was already removed.

0xC00D1452L

The method is not supported for cache proxy publishing points.

Remarks

The path must start with an appropriate prefix to indicate which data source plug-in to use. The following table provides examples of valid paths.

Path

Example

Media file

file:://C:\wmpub\wmroot\movie.wmv

file://\\server\directory\movie.wmv

Playlist file

file:://C:\wmpub\wmroot\playlist.wsx

file://\\server\directory\playlist.wsx

Stream from an encoder

http://encoder:port

Stream pushed to an encoder

push:*

Content from a publishing point on a local server

lpp://pubpoint/media.wmv

Stream from a publishing point on a local or remote server

rtsp://server/pubpoint

https://server/pubpoint

Stream from a station or publishing point on a version 4.1 server

https://server/stationname

https://server/pubpoint

Media file or playlist on a local or remote server

rtsp://server/pubpoint/movie.wmv

Playlist file from a Web server

https://server/playlist.asp

https://server/playlist.wsx

Directory of files

file://C:\wmpub\wmroot\directory

Multicast announcement file.

MCast://c:\wmpub\wmroot\file.nsc. Relative URLs cannot be used to specify this path.

Example

Imports Microsoft.WindowsMediaServices.Interop
Imports System.Runtime.InteropServices

Private Sub GetSetPath()

    ' Declare variables.
    Dim Server As WMSServer
    Dim PubPoints As IWMSPublishingPoints
    Dim PubPoint As IWMSPublishingPoint
    Dim strText As String

Try
    ' Create the WMSServer object.
    Server = New WMSServer()

    ' Retrieve the IWMSPublishingPoints object.
    PubPoints = Server.PublishingPoints

    ' Retrieve information about each publishing point.
    For Each PubPoint In PubPoints

        ' Retrieve the content path of the publishing point.
        strText = PubPoint.Path

        ' Set the content path of the publishing point.
        strText = "c:\wmpub\wmroot\"
        PubPoint.Path = strText

    Next

Catch excCom As COMException
    ' TODO: Handle COM exceptions.
Catch exc As Exception
    ' TODO: Handle errors.
Finally
    ' TODO: Clean-up code goes here.
End Try

End Sub

Requirements

Reference: Add a reference to Microsoft.WindowsMediaServices.

Namespace: Microsoft.WindowsMediaServices.Interop.

Assembly: Microsoft.WindowsMediaServices.dll.

Library: WMSServerTypeLib.dll.

Platform: Windows ServerĀ 2003 family, Windows ServerĀ 2008 family.

See Also

Reference

IWMSPublishingPoint Object (Visual Basic .NET)

IWMSPublishingPoint.Path (Visual Basic .NET)