none
Differentiate between User defined columns and default columns in sharepoint Online using CSOM RRS feed

  • Question

  • I want to Differentiate between User defined columns and default columns for a given list in SharePoint online using CSOM (using Microsoft.SharePoint.Client) . I searched alot but no luck. Anyone please suggest how to meet the above requirement or any workarounds.

    Thanks in Advance.


    TARUN

    Wednesday, March 1, 2017 8:24 AM

Answers

  • Hi achieved my requirement by using the below code snipet

     

     bool thisColumnWasCreatedByUser = fielditem.FromBaseType == false && (!fielditem.SchemaXml.Contains(" SourceID=\"http")) && (!fielditem.EntityPropertyName.StartsWith("OData__"));


    TARUN

    • Marked as answer by TARUN00197 Wednesday, March 1, 2017 9:31 AM
    Wednesday, March 1, 2017 9:31 AM

All replies

  • Hi achieved my requirement by using the below code snipet

     

     bool thisColumnWasCreatedByUser = fielditem.FromBaseType == false && (!fielditem.SchemaXml.Contains(" SourceID=\"http")) && (!fielditem.EntityPropertyName.StartsWith("OData__"));


    TARUN

    • Marked as answer by TARUN00197 Wednesday, March 1, 2017 9:31 AM
    Wednesday, March 1, 2017 9:31 AM
  • Hi,

    Thanks for your sharing, It will help others who suck with the problem!

    Best Regards,

    Dennis


    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com

    Thursday, March 2, 2017 1:40 AM
    Moderator