Casting Inline in Orchestration Expression Shape

Home Page › Forums › BizTalk 2004 – BizTalk 2010 › Casting Inline in Orchestration Expression Shape

Viewing 1 reply thread
  • Author
    Posts
    • #20170

      Hello,

      I’m trying to retreive some values from a section in my BTSNTSvc.exe.config file.  My original plan was to create an Orchestration variable of type Hashtable to hold the values, but ran into a problem when I discovered that hashtables weren’t serializable.  So I figured I’d be able to do this inline with some code like this:

      DaysOfWeek = System.Convert.ToString(((System.Collections.Hashtable)System.Configuration.ConfigurationManager.GetSection(“MySection”))[“DaysOfWeek”]);

      This works in C#, but unfortunately the expression shape doesn’t like it.  I know I could create a separate C# class to access my config information, but are there any other options for doing it completely within the orchestration?

      Thanks.

    • #20171

      You can write your one serializable hashTable.

      http://www.codeproject.com/KB/cs/IXmlSerializable.aspx

       

      Cheers,

      Pedro, O Moleiro

Viewing 1 reply thread
  • The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.