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 :
Finance | Project Operations, Human Resources, ...
Answered

Is possible clear use data of Particular Class?

(0) ShareShare
ReportReport
Posted on by 578

Only one user has problems with the display of a report and cleaning the user data resolves the problem, but loses its customization, for this reason it is only necessary to clean the data of the report controller class.

Is Possible?

For example this class

cache.PNG

Thanks in advance

I have the same question (0)
  • Suggested answer
    nmaenpaa Profile Picture
    101,166 Moderator on at

    Yes, it's possible. You can delete usage data per class, form or report.

  • ismaelivan Profile Picture
    578 on at

    Thanks Nikolaos, Will you have information about it that you can share with me?

    I try this without success

        xSession::removeAOC ();
        SysTreeNode::refreshAll ();
        SysFlushDictionary::doFlush ();
        SysFlushAOD::doFlush ();
        xSession::updateAOC ();
        
        And....
    
        #AOT ;
        TreeNode::findNode(#TablesPath).AOTrefresh();
        TreeNode::findNode(#TableMapsPath).AOTrefresh();
        TreeNode::findNode(#ViewsPath).AOTrefresh();
        TreeNode::findNode(#ExtendedDataTypesPath).AOTrefresh();
        TreeNode::findNode(#BaseEnumsPath).AOTrefresh();
        TreeNode::findNode(#LicenseCodesPath).AOTrefresh();
        TreeNode::findNode(#ConfigurationKeysPath).AOTrefresh();
        TreeNode::findNode(#SecurityKeysPath).AOTrefresh();
        TreeNode::findNode(#TableCollectionsPath).AOTrefresh();
        TreeNode::findNode(#PerspectivesPath).AOTrefresh();
        TreeNode::findNode(#MacrosPath).AOTrefresh();
        TreeNode::findNode(#ClassesPath).AOTrefresh();
        TreeNode::findNode(#ReportsPath).AOTrefresh();
        TreeNode::findNode(#ReportTemplatesPath).AOTrefresh();
        TreeNode::findNode(#SectionTemplatesPath).AOTrefresh();
        TreeNode::findNode(#QueriesPath).AOTrefresh();
        TreeNode::findNode(#JobsPath).AOTrefresh();
        Dictionary::aodFlush();
        Dictionary::dataFlush();
        flush UtilElements, UtilIdElements;

  • Verified answer
    Martin Dráb Profile Picture
    239,069 Most Valuable Professional on at

    You can delete the record from SysLastValue table.

  • ismaelivan Profile Picture
    578 on at

    Thanks Martín,

    it worked! Here I leave this little Job

    private void ClearUserData()
    {
        UserInfo userinfo;
        SysLastValue   syslastvalue;
        Dialog dialog;
        DialogField field1, field2, Items;
        FormBuildComboBoxControl combousers, comboelements;
        Description description;
        int numitems = 0;
        container usercont, elementcont;
        UserId userid;
        Description element;
    
        dialog = new Dialog("Borrar Datos de Uso");
    
        dialog.dialogForm().form().design().left(44, 4); //center
        dialog.dialogForm().form().design().top(220, 3); //center
    
    
        Items = dialog.addField(EnumStr(ABC));//,toDate);
        combousers = Items.control();
        combousers.enumType(0);
        combousers.label("Seleccione Usuario");
        
        while select userinfo
            numitems  ;
        
        combousers.items(numitems);
        numitems = 0;
        
        while select userinfo
        {
            numitems  ;
            combousers.item(numitems);
            combousers.text(userinfo.id);
            usercont  = userinfo.id;
        }
        
        dialog.run();
    
        if (dialog.closedOk()) // && field1.value() != "")
        {            
            userid = conpeek(usercont,Items.value()   1);
            
            dialog = new Dialog("Borrar Datos de Uso");
            dialog.dialogForm().form().design().left(44, 4); //center
            dialog.dialogForm().form().design().top(220, 3); //center
            //dialog.addText("Seleccione un Elemento a Eliminar");
    
            Items = dialog.addField(EnumStr(ABC));//,toDate);
    
            comboelements = Items.control();
            comboelements.enumType(0);
            comboelements.label("Elemento");
            
            numitems = 0;
            
            while select syslastvalue group by syslastvalue.elementName where syslastvalue.userId == userid
                numitems  ;
            
            comboelements.items(numitems);
    
            numitems = 0;            
            
            while select syslastvalue group by syslastvalue.elementName where syslastvalue.userId == userid
            {
                numitems  ;
                comboelements.item(numitems);
                comboelements.text(syslastvalue.elementName);
                elementcont  = syslastvalue.elementName;
            }
            
            dialog.dialogForm().form().design().left(44, 4); //center
            dialog.dialogForm().form().design().top(220, 3); //center
            
            dialog.run();
    
    
            if (dialog.closedOk())
            {
                element = conpeek(elementcont,Items.value()   1);
    
                ttsBegin;
                
                while select forUpdate syslastvalue 
                where syslastvalue.userId == userid && syslastvalue.elementName == element
                { 
                    syslastvalue.delete();
                }
                
                ttsCommit;
                
                Box::info("Eliminado.");
            }
            else
            {
                Box::info("No se pudo eliminar.");
            }
        }
    }

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 658

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 495 Super User 2026 Season 1

#3
Syed Haris Shah Profile Picture

Syed Haris Shah 315 Super User 2026 Season 1

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans