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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

How Can I get Personal settings in dynamics with c# in plugin

(0) ShareShare
ReportReport
Posted on by

AOA!

Kindly Guide me That how can we get the personal setting in dynamics 365 with c# in plugin i wanna get several record information i am confused that how can we get the personal settings of dynamics 365 with c# in plugin

Regards:

noor ul amin

I have the same question (0)
  • Verified answer
    meelamri Profile Picture
    13,216 User Group Leader on at

    Hi noor ul amin,

    you can find the personal options for a user at the entity level: usersettings. Below is a query that retrieves the personal settings for all users with the last name "XXX".

    FetchXML: 

      
        
          
            
          
        
      
    

    QueryExpression:

    // Define Condition Values
    var query_systemuser_lastname = "XXX";
    
    // Instantiate QueryExpression query
    var query = new QueryExpression("usersettings");
    
    // Add all columns to query.ColumnSet
    query.ColumnSet.AllColumns = true;
    
    // Add link-entity query_systemuser
    var query_systemuser = query.AddLink("systemuser", "systemuserid", "systemuserid");
    
    // Define filter query_systemuser.LinkCriteria
    query_systemuser.LinkCriteria.AddCondition("lastname", ConditionOperator.Equal, query_systemuser_lastname);
    

    Good Luck !!

  • Noor Ul amin Profile Picture
    on at

    Can you share me the screen shot of the Xml condition you used when u created this Query

    regards:

    noor ul amin

  • Verified answer
    meelamri Profile Picture
    13,216 User Group Leader on at

    I used fetchXML Builder: 

    pastedimage1632217295452v1.png

  • Verified answer
    CRMJetty Profile Picture
    3,512 on at

    Hi,

    You can get personal settings of user from usersettings entity.

    Use below code to get current user personal settings:

    QueryExpression userSettingsQuery = new QueryExpression("usersettings")
    {
        ColumnSet = new ColumnSet(true),
            Criteria = new FilterExpression
            {
                Conditions =
                {
                    new ConditionExpression("systemuserid", ConditionOperator.EqualUserId)
                }
        }
    };
    
    DataCollection currentUserSettings = _serviceProxy.RetrieveMultiple(userSettingsQuery).Entities;

    I hope it helps,

    Thanks.

    Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Tom_Gioielli Profile Picture

Tom_Gioielli 108 Super User 2025 Season 2

#2
Jimmy Passeti Profile Picture

Jimmy Passeti 50 Most Valuable Professional

#3
Gerardo Rentería García Profile Picture

Gerardo Rentería Ga... 49 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans