BizTalk Server Applications Integration - Pass Through data to AIC

This is Interesting: Free IT Magazines  
Home > Archive > BizTalk Server Applications Integration > April 2004 > Pass Through data to AIC





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Pass Through data to AIC
Curt Vasbinder

2004-04-19, 6:36 pm

I am using BizTalk 2002 and need to have the receive function pickup the file send it to the channel/port as passthru. In the port I have the primary transport as a lightweight AIC, but because I am using a passthru, the data in not coming into the AIC a
s ASCII chaacters. How do I convert the data using c#?
mark

2004-04-21, 3:35 am

Hi,
here's a small code snippet. It could be improved
but it should give you some ideas to work with.

// Is this a PassThru?
bool IsPassThru=false;
object PT = dict["IsPassThrough"];
if (null != PT)
{
if (DBNull.Value != PT)
IsPassThru = Convert.ToBoolean(dict["IsPassThrough"]);
}

if (IsPassThru)
{
UnicodeEncoding unicBSTR = new UnicodeEncoding();
Byte[] encodedBSTR = unicBSTR.GetBytes((string)dict["working_data"]);
int biztalkLength = (int) dict["PTDataLen"];
FileStream fs = new FileStream(strLocalFilename, FileMode.Create);
BinaryWriter w = new BinaryWriter(fs);
w.Write(encodedBSTR);
w.Close();
fs.Close();
}
Curt Vasbinder

2004-04-29, 2:37 pm

Mark, this was the trick that I needed. Thanks for your help.....
Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com