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

Community site session details

Session Id :

Change form background color in dynamics Ax

Mohamed Asarafali Profile Picture Mohamed Asarafali 445
How to change form background color overall in AX

Problem : I was assigned by a task to change the background color of a form by company 
               so user can differentiate between companies.

Solution
               
                 Class Name : SysSetupFormRun

              Overrides the run method with following code

              public void run()
              {
                            ;
                            super();
                            switch(curext)
                            {
                                    case "AYN":
                                                       this.design().colorScheme(FormColorScheme::RGB);
                                                       this.design().backgroundColor(WinAPI::RGB2int( 204,255,0));  
                                                       break;
                                   case "CAT":
                                                       this.design().colorScheme(FormColorScheme::RGB);
                                                       this.design().backgroundColor(WinAPI::RGB2int (155,255,0));
                                                       break;
                             }
                 }
                 it solved my problem

                    
                 



This was originally posted here.

Comments

*This post is locked for comments