locked
Content Correlation with XMLSerializer Option RRS feed

  • Question

  • Hi,

    i tried to use Content Correlation with XMLSerializer for WF 4 Service.

    However if i try to initialize it on a starting Receive Activity i can' select an xpath-attribute.

    In the following activities i can normally select CorrelatesOn attributes, tho Visual Studio seems to ignore the correct XMLSchema the XMLSerializer would create.

    e.g. sm:body()/xg0:OrderResponseSimpleType/xg0:orderReferenceField would really be sm:body()/xg0:OrderResponse/xg0:OrderReference because of a XmlRootAttribute("OrderResponse") and an ID Property.

    Moreover it looks like the workflow can't start with XMLSerializer Option and Content Correlation (I added the initializers manually in the Xamlx Code).

    I used xsd.exe to generate Message Type classes, which can't be transformed as a datacontract (containing attributes like string[]).

    Are my observations known issues with Visual Studio Designer? It just doesn't work i think with XMLSerializer and Correlation.

    Yours Stefan



    • Edited by S.Kolb Thursday, May 24, 2012 8:56 AM addition
    Wednesday, May 23, 2012 2:25 PM

All replies

  • Hi,

    Could you please provider a sample project for us download or send it to me at: liangliang(dot)tang(at)hotmail(dot)com? It will be convenient for us to reproduce this issue. Thanks.


    Leo Tang [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Thursday, May 24, 2012 10:41 AM
  • Hi,

    i used Visual Studio 4.0.30319SP1Rel, Project is .NET Framework 4 Platform Update 1.

    I provide two projects: 

    - XMLSerializerCorrelationProblem (http://goo.gl/H2R82)

    - XMLSerializerCorrelationManualFix (http://goo.gl/eP4cg)

    You can reproduce my problem as following:

    Use XMLSerializerCorrelationProblem Project

    1. Select first Receive activity and try to select xpath query  for Query correlation initializer under CorrelationInitializers, won't work for me (it's deactivated).

    2. I can select the SharedHandle for the second receive activity. I can even select a CorrelatesOn XPath Query now!

    However it is wrong, as VS automatically used DataContractSerializer for the query (You can see this in the Xaml Code).

    Use XMLSerializerCorrelationManualFix Project

    3. I adjusted the necessary correlation manually in the xamlx and it works.

    All in all this use case with XmlSerializer doesnt seem to work right now.

    Yours Stefan


    • Edited by S.Kolb Thursday, May 24, 2012 1:44 PM
    Thursday, May 24, 2012 11:52 AM
  • Hi,

    Sorry, I can't download the projects duce to proxy issue. Can you send a copy to me ? Thanks.


    Leo Tang [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Friday, May 25, 2012 7:11 AM
  • Hi,

    I sent you the projects in an email. Hope you received it.

    Yours

    Stefan Kolb

    Sunday, May 27, 2012 12:49 PM
  • Can anyone come back to this topic or Leo can you just answer me if you took a look at the problem?
    Friday, June 15, 2012 1:04 PM