This project has moved and is read-only. For the latest updates, please go here.
1

Closed

SchemaData.SchemaUrl should not be a Uri

description

The SchemaUrl of a SchemaData does not have to be a valid Uri. Requiring Uri as the type means that you cannot use this properly. See the section about schemaData.

Notice that schemaUrl can be anyURI. In the example the following is given
<SchemaData schemaUrl="#TrailHeadTypeId">
Trying to create a Uri with the text #TrailHeadTypeId will throw an exception: "Invalid URI: The format of the URI could not be determined."
Closed Jul 20 at 6:15 AM by samcragg
You can make relative URIs by using the overloaded constructor, as discussed here: http://sharpkml.codeplex.com/discussions/429021

var uri = new Uri("#TrailHeadTypeId", UriKind.Relative);

comments

skendrot wrote Jul 20 at 3:04 PM

Thanks. Forgot about relative uris!