Microsoft.XLANGs.Core.Service.RootService.ApplyTransform
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > BizTalk Server > BizTalk Server > Microsoft.XLANGs.Core.Service.RootService.ApplyTransform




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Microsoft.XLANGs.Core.Service.RootService.ApplyTransform  
OgTheTerror


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
11-22-06 12:23 PM

Hi there guys

I know there was a old Post on this subject but it has since been
closed, I know this method can be called from a Orchestration as
Highlighted in the example below found in the other post aswell as the
Biztalk Help.

What I however would like to know is there anyway to call
Microsoft.XLANGs.Core.Service.RootService.ApplyTransform() from a
dot.net assembly?


Example:
----------

if (condition)
{
MapType = Type.GetType("NameSpace1.Map1, AssemblyName1,
Version=1.0.0.0,Culture=neutral, PublicKeyToken=111111111111");
}
else
{
MapType = Type.GetType("NameSpace2.Map2, AssemblyName2,
Version=1.0.0.0,Culture=neutral, PublicKeyToken=111111111111");
}

// use the map type in the transform
construct _responseMessage
{
transform (responseMessage.x1, _responseMessage.x2) =
MapType(requestMessage.s1, _requestMessage.s2);
}

// or you can use the fully-qualified map name in the transform
construct _responseMessage
{
transform (_responseMessage.x1, _responseMessage.x2) =
NameSpace.MapName (requestMessage.s1, _requestMessage.s2);
}






[ Post a follow-up to this message ]



    Re: Microsoft.XLANGs.Core.Service.RootService.ApplyTransform  
OgTheTerror


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
11-22-06 12:23 PM

Hi there guys

I'd like to Elaborate further on what im trying to do, the best way i
can think of to get that accross is to show you the code!!!

public static XLANGMessage mapXLANGMsg(XLANGMessage inPutMsg)
{
XLANGMessage outPutMsg = null;
Part outPutPart = null;
try
{
if (inPutMsg != null && inPutMsg.Count > 0)
{
IEnumerator e = inPutMsg.GetEnumerator();
XLANGPart inXLANGpart = null;
object[] objinPutParts = new object[10];
Int32 i = 0;

while (e.MoveNext())
{
inXLANGpart = (XLANGPart)e.Current;
if (inXLANGpart != null)
{
XmlDocument xmlDoc = new XmlDocument();
xmlDoc =
(XmlDocument)inXLANGpart.RetrieveAs(xmlDoc.GetType());

//This is not allowed null Reference
exception is caused
//Part inPart = null;
//inPart.LoadFrom(xmlDoc.OuterXml);

objinPutParts[i] = inXLANGpart;

i++;
}
}
//This seems to only accept Part's
ServiceContext.RootService.ApplyTransform(MapType,
new object[] { outPutPart }, objinPutParts);

//Then the question is how do I get back to a
XLANGMessage???
}
}
catch (Exception ex)
{
}
return outPutMsg;
}






[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 01:58 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register