Taal

PackUriHelper.GetRelativeUri(Uri, Uri) Methode

Definitie

Retourneert de relatieve URI tussen twee opgegeven PackagePart URI's.

public:
 static Uri ^ GetRelativeUri(Uri ^ sourcePartUri, Uri ^ targetPartUri);
public static Uri GetRelativeUri(Uri sourcePartUri, Uri targetPartUri);
static member GetRelativeUri : Uri * Uri -> Uri
Public Shared Function GetRelativeUri (sourcePartUri As Uri, targetPartUri As Uri) As Uri

Parameters

sourcePartUri
Uri

De URI van het brononderdeel.

targetPartUri
Uri

De URI van het doelonderdeel.

Retouren

Uri

De relatieve URI van sourcePartUri tot targetPartUri.

Uitzonderingen

sourcePartUri of targetPartUri is null.

sourcePartUri De of targetPartUri heeft geen geldige Uri syntaxis.

Opmerkingen

In de volgende tabel ziet u voorbeeldvoorbeelden voor GetRelativeUri.

sourcePartUri targetPartUri Geretourneerde relatieve URI
/mydoc/markup/page.xml /mydoc/markup/picture.jpg picture.jpg
/mydoc/markup/page.xml /mydoc/picture.jpg .. /picture.jpg
/mydoc/markup/page.xml /mydoc/images/picture.jpg .. /images/picture.jpg

Van toepassing op

Zie ook