locked
Service Correlation - Cannot find a path to the member when generating the XPath query. RRS feed

  • Question

  • I'm trying to use the Workflow Designer in VS2010 Beta 1 to set a workflow correlation to a property on one of my domain objects.  The property is of type Guid.  When I select the property, I get this error message:

    ---------------------------
    Correlations
    ---------------------------
    Cannot find a path to the member when generating the XPath query.
    ---------------------------
    OK   
    ---------------------------

    If I choose my whole domain object to base the correlation on, then an XPath is generated, which is: //xg0:DomainObject. I'm unsure what the proper XPath expression should be.  The property on the domain object is "ID", which is again, type Guid.

    Monday, September 21, 2009 1:45 PM

Answers

  • Fixed it.  Adding datacontract / datamember attributes to the class allowed the designer to generate an xpath.  Thanks Matt for your help!
    • Marked as answer by RyanHoff Wednesday, September 23, 2009 3:56 AM
    Wednesday, September 23, 2009 3:56 AM

All replies

  • Just to help someone else answer this question:
    What is the declaration of DomainObject.ID? Is there anything else special about the DomainObject class?

    Monday, September 21, 2009 5:17 PM
  • Have you tried selecting the object then editing the xPath?  I did that with a collection and it worked fine.  Is your object a DataContract, or a simple .NET class?  If not a datacontract, then it will serialize differently, and you may need to refer to the private backing field instead of the public property. 

    HTH

    Matt
    Check out Pluralsight On Demand! http://www.pluralsight.com/main/olt/
    Monday, September 21, 2009 6:57 PM
  • Fixed it.  Adding datacontract / datamember attributes to the class allowed the designer to generate an xpath.  Thanks Matt for your help!
    • Marked as answer by RyanHoff Wednesday, September 23, 2009 3:56 AM
    Wednesday, September 23, 2009 3:56 AM