web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Get list of fields in forms

(0) ShareShare
ReportReport
Posted on by 760

Hi,

Is there a way I can get the list of fields including the fields in the tables in the form? 

Aside from excel templates

*This post is locked for comments

  • Suggested answer
    Syed Ibrahim Profile Picture
    6,257 on at

    Yes. You can export all the metadata and fields requirements, description etc using metadata extractor in XrmToolBox tool. You can download using below url.

    https://www.xrmtoolbox.com/

  • Suggested answer
    Srujan K Profile Picture
    317 on at

    Not sure if this is the best way, But you can follow the below steps.

    1.  Update the data in all the fields present on the form.

    2.  From Advanced Find, Export the record with all the columns.

    3.  Delete the columns without data from the excel and the row with data.

    4. Copy paste the row with column names in excel using 'Transpose' Option , You will get the list of columns on the Form.

  • Suggested answer
    Aric Levin - MVP Profile Picture
    30,190 Moderator on at

    Probably XRMToolbox would be the easiest way to do this, but in case you want to use the SDK, you can use the following code:

           public void GetAttributes(string entityName)

           {

               RetrieveEntityRequest request = new RetrieveEntityRequest()

               {

                   LogicalName = entityName,

                   EntityFilters = EntityFilters.All,

                   RetrieveAsIfPublished = true

               };

               RetrieveEntityResponse response = (RetrieveEntityResponse)service.Execute(request);

               GetAttributes(response.EntityMetadata.Attributes);

           }

           private void CreateAttributes(AttributeMetadata[] metadata)

           {

               // This will also get the Virtual Attributes

               foreach (AttributeMetadata attr in metadata)

               {

                   string logicalName = attr.LogicalName;

                   string attrType = attr.AttributeType.ToString();

                   string displayName = attr.DisplayName.LocalizedLabels.Count > 0 ? attr.DisplayName.LocalizedLabels[0].Label : string.Empty;

                   bool isPrimary = false;

                   if (attr.IsPrimaryId.HasValue && attr.IsPrimaryId.Value == true)

                       isPrimary = true;

                   else if (attr.IsPrimaryName.HasValue && attr.IsPrimaryName.Value == true)

                       isPrimary = true;

               }

           }

  • Suggested answer
    Srikanta Mahapatro Profile Picture
    190 on at

    Hi,

    Connect to XRMToolBox for dynamics 365.

    Open the Metadata Document Generator

    Select the "All attributed Contained in Form" from for "Generate For" attribute selection

    On Right side you will got the list of Form name

    select the desired form and download

    5758.Attributes.PNG

  • Suggested answer
    Rawish Kumar Profile Picture
    13,758 on at

    Agree with Srikanta, used this option couple of times.

    instructions here : carldesouza.com/xrmtoolbox-metadata-document-generator

  • shivat Profile Picture
    15 on at

    It's not working when we select that option. try that option and let us know . 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans