I am editing metadata via a VB.NET Addin. Update information comes from ASCII files and I am and looking for a way to insert new lines.
In this simple example the ASCII text provided might look like: "Administrator: Person A"
Using the IXmlPropertySet2 interfacemy code looks something like this:
Dim sName As String = "mdContact/rpPosName"
Dim sValue As Object = "Administrator: \r\n Person A" 'update string with escape sequence added
XmlPropertySet2.SetPropertyX(sName, sValue, esriXmlPropertyType.esriXPTText, esriXmlSetPropertyAction.esriXSPAAddOrReplace, False)
Setting the property type to esriXPTText suggests that the value parameter (sValue in this example) should be a string. However any escape characters inserted in the string are not interpreted correctly and instead are shown as normal text in the metadata viewer. Being at a loss what the correct escape character might be I tried quite a variety: <\r\n> <br>, 
 <br> \r\n
I have seen the somewhat similar thread https://community.esri.com/thread/213315-new-line-in-metadata-summary-description but this does not fit my problem.
Any ideas how to insert new lines?
Just an idea, no idea if it will work, have you tried the vb constant vbNewLine?
Duncan,
thanks for the input but vbNewLine (or vbCrLf for that matter) will not work. I alredy thought to use <br> (the interface is called XmlPropertySet after all) but I am not very versed with xml and did not make it work either. Any other ideas?