dereferrencing in layoutxml RRS feed

  • Question

  • in a savedquery layoutxml for a grandchild attribute would the expression be:

    • cell name='customentity.statecode... OR
    • cell name='contact.customentity.statecode...
    Monday, April 18, 2016 11:26 PM

All replies

  • better question, can I use grandchildren:

    <grid name='resultset' object='10006' jump='new_name' select='1' icon='1' preview='1'>
      <row name='result' id='new_ticketid'>
        <cell name='new_contactid' width='200' />
        <cell name='new_duedate' width='100' />
        <cell name='new_name' width='200' />
        <cell name='new_description' width='300' disableSorting='1' />
        <cell name='contact.gendercode' width='100' disableSorting='1' />
        <cell name='contact.new_primarylocationid' width='100' disableSorting='1' />
        <cell name='currenroll.new_programid' width='100' disableSorting='1' />
        <cell name='createdon' width='100' />
        <cell name='ownerid' width='100' />
    <fetch version='1.0' output-format='xml-platform' mapping='logical' distinct='false'>
      <entity name='new_ticket'>
        <attribute name='new_contactid' />
        <attribute name='new_duedate' />
        <attribute name='new_name' />
        <attribute name='new_description' />
        <attribute name='createdon' />
        <attribute name='ownerid' />
        <order attribute='new_name' descending='false' />
        <filter type='and'>
          <condition attribute='statecode' operator='eq' value='0' />
        <link-entity name='contact' from='contactid' to='new_contactid' alias='contact'>
          <attribute name='new_primarylocationid' />
          <attribute name='gendercode' />
          <link-entity name='new_enrollment' from='new_enrollmentid' to='new_primaryenrollmentid' alias='currenroll'>
            <attribute name='new_programid' />
        <attribute name='new_ticketid' />

    the grandchild is 

        <cell name='currenroll.new_programid' width='100' disableSorting='1' />

    when I test the fetch, it identifies currenroll.new_programid as a legitimate key in the Attributes collection keyValuePairs.  But when I come back to CRM the system view definition bangs (!) the column and gives the message "The currenroll.new_programid column is no longer a valid column because it has been deleted as a column option. You need to remove this column and, if you want, add a different one."

    What's the problem?  Are grandchildren not valid options?

    Thanks for checking in.

    Tuesday, April 19, 2016 1:46 AM
  • PS- this is the fetchXML test I used:

                EntityCollection Es = service.RetrieveMultiple(new FetchExpression(FetchXML));
                Entity firstone = Es.Entities[0];
                foreach (KeyValuePair<string, object> att in firstone.Attributes)

    Tuesday, April 19, 2016 1:57 AM
  • no idea, eh?
    Friday, April 22, 2016 4:59 PM