A few years a go I made a few posts about numbersequences, in these posts I forgot to mention that you need to execute the following job before you can find your new created Numbersequence. static void NumberSeqLoadAll(Args _args) { NumberSeqApplicationModule::loadAll(); }static void NumberSeqLoadAll(Args _args) { NumberSeqApplicationModule::loadAll(); }
Archives
Maximize a form in Ax
Change the properties width = ‘column width’ and height = ‘column height’ on the form. Add the following code in the run-method of the form: #WinApi ; super(); WinApi::showWindow(this.hWnd(), #SW_SHOWMAXIMIZED);#WinApi ; super(); WinApi::showWindow(this.hWnd(), #SW_SHOWMAXIMIZED);
Microsoft Dynamics AX 2012 X++ Editor Extensions
Improve your Ax 2012 code editor with Some extensions found on CodePlex.
Change the language at runtime
Normally when you change your language you go to your user options, change your current language and the restart the client. This week I got the question if it was possible to do so in runtime. You can do so by just calling the infolog.language(str 7 _languageCode). All labels that you load after calling this … Continue Reading
Amount in words
This week one of my customers asked me to place the amount in words on a invoice. I couldn’t believe that sush function wasn’t availible in standard Ax. After some research I found that the Global-class contains the following methods: static TempStr numeralsToTxt(real _num) static TempStr numeralsToTxt_EN(real _num) static TempStr numeralsToTxt_ES(real _num) static TempStr numeralsToTxt_FR(real … Continue Reading
Index vs Index hint
This is a discussion I had with several colleagues. What is the difference between index and index hint and what do we use in our code?
Testing code on client/server
When you quickly want to test some code I often write some test-code in a small job. When you execute the code in this job, it will be executed on client-side. A colleague of mine asked me if he could test the same job while running on server-side. Wen you quickly want to test the … Continue Reading
Loop all tables
There is a simple trick to loop all tables that are available in Ax. Just use the Dictionary-class that contains all information about tables. Small example to list all tablenames + their corresponding Id. 1 2 3 4 5 6 7 8 9 10 static void JeDoe_listTables(Args _args) { Dictionary dictionary = new Dictionary(); int … Continue Reading
Records with RecId 101090
I was using the postload method of the HRMBenefitType-table to fill the description-field with language-sensitive description (from LanguageTxt). This works fine when I view the record, but not when I use a lookup. I’ve put a break-point on my postload method and noticed the recId (this.recid of the HRMBenefitType table). This is always the 101090. … Continue Reading
Dialog Extended
One of my colleagues (Koen Dedecker) was looking for a way to prevent user interaction with other forms while a certain dialog is shown. After some research he found the solution on the blog Dynamics AX tools and tutorials from Vanya Kashperuk. A few years ago (2007) he made a simple extension of the dialog class … Continue Reading