A document library in SharePoint contains several Content Types. BizTalk will upload documents to the document library in SharePoint.
When uploading via BizTalk the document to SharePoint, I need to say which Content Type the document is linked too.
When uploading the document and adding the Metadata needed for the content type of the document, I saw that SharePoint always uses the default content type.
So metadata not used in the default content type is discharged.
How can I tell the WSS adapter which content type to use?
The solution is very simple; the name of the content type is also metadata.
In the orchestration, add a Message Assign Shape
Add the following code to the Message Assign Shape:
SharePointOutMsg(WSS.ConfigPropertiesXml) = "<ConfigPropertiesXml><PropertyName1>Content Type</PropertyName1><PropertySource1>My Custom ContentType</PropertySource1> [Add more custom metadata] </ConfigPropertiesXml>";