Personalized Community is here!
Quickly customize your community to find the content you seek.
Choose your path Increase your proficiency with the Dynamics 365 applications that you already use and learn more about the apps that interest you. Up your game with a learning path tailored to today's Dynamics 365 masterminds and designed to prepare you for industry-recognized Microsoft certifications.
Visit Microsoft Learn
2020 Release Wave 2Discover the latest updates and new features to Dynamics 365 planned through March 2021.
Release overview guides and videos Release Plan | Preview 2020 Release Wave 2 TimelineWatch the 2020 Release Wave 1 virtual launch event
Ace your Dynamics 365 deployment with packaged services delivered by expert consultants. | Explore service offerings
Connect with the ISV success team on the latest roadmap, developer tool for AppSource certification, and ISV community engagements | ISV self-service portal
The FastTrack program is designed to help you accelerate your Dynamics 365 deployment with confidence.
FastTrack Program | Finance TechTalks | Customer Engagement TechTalks | Upcoming TechTalks
I have some code that is needed to be called after a user changes the company. Can any one please help me identify if there are any methods which get called after company has been changed in AX.
The following method changes the Company for the user, when they are using the change company dialog:
If you want to cover every area in the system where you can change companies, you will need to start looking into the Application class. Take a look at the setDefaultCompany method. There is a warning output there that warns the user that they have changed companies (as long as they have this warning turned on in user options). Depending on your requirements, you can use this same type of functionality to handle a change of companies.
Hope this helps, good luck!
I suggest you should consider overrriding following
just before return statement
If you review this method you will find that system is setting all the required variables before return statement
so you should put your code after all the required variables are set.
Please verify and udpate us with your findings.
Thanks for the replies guys, I would try these out and would let you know,
Eid Mubarak ! :)
HI Nitesh & Nayyar,
I have the same type of requirement.
I am able to hide the modules if I write the code in SwitchCompany() of SysDataAreaSelect. But if I call my class which is hiding the module in the Application class (setDefaultCompany) method, AX is chrashing once I change company from the address bar.
Please note, I have called my class just before the "return" statement of the setDefaultCompany method. Please help.
Thanks in advance!
Business Applications communities