title: How do I use System.Activities.Validation.GetParentChain?
body: <p>I've got an Outer activity which has a Body onto which you drag other activities.  I then have several Inner activities, which MUST be a descendent of an Outer activity.  I'd like to add design-time validation to ensure the Inner is placed within an Outer.</p>
  
  <p>I've heard that I "<a href="http://social.msdn.microsoft.com/Forums/en-US/wfprerelease/thread/5518c991-5075-403a-911d-bcd480e2f769" rel="noreferrer">can use System.Activities.Validation.GetParentChain to enumerate all of the parents of an activity during the validation step</a>".  But even after reading <a href="http://msdn.microsoft.com/en-us/library/system.activities.validation.getparentchain.aspx" rel="noreferrer">the documentation for the class</a>, I have no idea how to use it.  </p>
  
  <p>I would think I use it inside CacheMetadata in my Inner class.  I'd like to use have a foreach(var ancestor in parentChain) { ... }, and make sure at least one ancestor is of type Outer.  Not sure how to do that.</p>
  
  <p>Can anyone explain how to validate at design time that an Inner activity is a descendant of an Outer activity?</p>