Talk About Network

Google





Software > Biz Talk Orchestration > Re: Calling an ...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 3 of 3 Topic 4094 of 4234
Post > Topic >>

Re: Calling an external assembly from Custom XSLT

by "Zoe Hart" <zoe.hart@[EMAIL PROTECTED] > Mar 20, 2008 at 08:26 AM

You are correct. I don't need the scripting functoid. I was just using that

as a means of accessing my external assembly. I will try the approach you 
describe instead.

Thanks,
Zoe

"Randal van Splunteren" <Randal.van.Splunteren@[EMAIL PROTECTED]
> wrote in
message 
news:O3TS9iZiIHA.4344@[EMAIL PROTECTED]
> Hi Zoe,
>
> You can add a custom extension xml file to your solution in order to 
> declare
> the namespace and use a method from a .Net assembly from XSL.
>
> The extension file should look something like this:
>
> <ExtensionObjects>
>    <ExtensionObject Namespace="http://mapHelper"
> AssemblyName="MyHelperAssembly, Version=1.0.0.0, Culture=neutral,
> PublicKeyToken=..." ClassName="MyHelper.MappingHelper"/>
> </ExtensionObjects>
>
> In the properties of your BizTalk map point the value of the 'custom
> extension file' property to the file above.
>
> Finally in your xsl you can use the method from the assembly. For
example:
>
> <xsl:variable name="methodResult" xmlns:mapHelper="http://mapHelper"
> select="MappingHelper:DoMethod()" />
> <xsl:value-of select="$methodResult" />
>
> Although this solution doesn't use a scripting functoid as an external
> assembly you can use it to call a custom .Net method from your code. If
I
> interpret your question correctly that is what you need to do.
>
> HTH,
>
> Randal van Splunteren
>
> "Zoe Hart" <zoe.hart@[EMAIL PROTECTED]
> wrote in message
> news:%23Z0K9zSiIHA.4376@[EMAIL PROTECTED]
>> I have several instances where I put a Scripting Functoid in my map,
>> configure it as Inline Visual Basic .NET, and then call that function 
>> from
>> my Custom XSLT using the userVB namespace. Now I want to be able to do 
>> the
>> same thing with a Scripting Functoid configured as an External
Assembly.
> If
>> I drop the Scripting Functoid in the map, configure it as an External
>> Assembly, and then use it directly in the map (connecting its inputs
and
>> outputs directly to the source and target schemas) and then do Validate
> Map
>> to see the resultant XSL, the XSL includes a declaration of the
namespace
>> ScriptNS0 as http://schemas.microsoft.com/BizTalk/2003/ScriptNS0.
The
> calls
>> to the external function then use this ScriptNS0 namespace. But if I
> remove
>> the input and output connections from the functoid and try to call it 
>> from
>> my custom XSLT, the namespace isn't defined. When I do the same thing 
>> with
>> an Inline Visual Basic .NET scripting functoid, the namespace
declaration
> is
>> automatically added to the XSL.
>>
>> So how can I configure a scripting functoid as External Assembly and
call
> it
>> from my custom XSLT?
>>
>> Thanks,
>> Zoe
>>
>>
>
>
 




 3 Posts in Topic:
Calling an external assembly from Custom XSLT
"Zoe Hart" <  2008-03-18 15:19:27 
Re: Calling an external assembly from Custom XSLT
"Randal van Splunter  2008-03-19 09:10:43 
Re: Calling an external assembly from Custom XSLT
"Zoe Hart" <  2008-03-20 08:26:01 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
localhost-V2008-12-19 Thu Jan 8 17:27:15 PST 2009.