05-30-06 12:15 PM
If you wish to insert Xml into the destination that did not originate in the
source you need to use <xsl:value-of> and a string representation of the Xml
A scripting functoid like
public string GetXml(XmlDocument doc)
{
return doc.OuterXml;
}
then use an inline XSLT
<xsl:value-of disable-output-escaping="yes"
select="userCSharp:GetXml(yourXmldoc"/>
Greg
"Obiwan Jacobi" <obiwanjacobi@hotmail.com> wrote in message
news:1148980070.728191.41800@i40g2000cwc.googlegroups.com...
> Hi,
>
> I'm a BizTalk newbee and I am trying to enrich a message. Most of the
> fields can be copied direcly and a database lookup should provide the
> rest of the information. The information that is to be added to the
> destination message is complex; a hierarchy with multiple repeating
> elements.
>
> I've tried to use a Map and a Database Lookup functoid. But this only
> works well for single field (one row at best) enrichment. Then I tried
> to use the scripting functoid to call an external assembly that looks
> up the extra information. But there was no way I got the extra
> information to be copied into the destination schema. I've tried
> returning a custom Xml serializable class, an XmlDocument, an XmlNode
> and a string containing the xml. Either the new element was not added
> at all or I got an error the element could not contain text (as defined
> in the destiniation schema).
>
> I also tried to pass the output of the scripting functoid that calls
> the external assembly into another scripting functoid that contained an
> xslt call template. But I didn't know how to copy the XmlDocument in
> the <xsl:param> out to the destination. I've tried <xsl:copy-of
> select="document($param1)"/> but that didn't work.
>
> So if anyone has any idea how to get an xml fragment into the
> destination schema. I would be very gratefull.
>
> Thanx
> Marc Jacobi
>
[ Post a follow-up to this message ]
|