There is a verry simple trick to loop through some companies and execute some code in them. Just write: DataArea dataArea; ; while select dataArea where !dataArea.isVirtual { changecompany(dataArea.id) { // Do Something… } }DataArea dataArea; ; while select dataArea where !dataArea.isVirtual { changecompany(dataArea.id) { // Do Something… } } Note! Make sure that you … Continue Reading
Category
Microsoft
Batch job performance boost
Did you ever have trouble with the performance of your batch-job? Well maybe this small trick can shorten the time your batch runs. The big idea: Try to split up your gigantic batch in smaller pieces. Launch a batchjob that produces many smaller batchjobs (tasks) that can handle a subset of the data you need to … Continue Reading
Techdays 2010 @ Antwerp – Channel9
A few weeks ago I attended Techdays 2010. Now you all video’s ave been posted on Channel9. Check them out on: http://channel9.msdn.com/tags/TechDaysBelux/ Enjoy!
Tip for overriding methods
There is a simple and generic way to force overriding a method you created. To do so you just need create your new method and place a ‘throw error’ statement in it. To finish you can add the static method missingOverride from the error class and the funcName() to your error. Now when this method … Continue Reading
Expressions in query ranges – limitations
When you want to construct a query-object that contains OR-conditions, you can construct something like this: 1 2 3 4 5 6 queryBuildRange.value(strFmt('((%1 == %2) || ((%1 == %3) && (%4 == "%5")))’, fieldStr(InventTable, ItemType), any2int(ItemType::Service), any2int(ItemType::Item), fieldStr(InventTable, ProjCategoryId), queryValue("Spares")));queryBuildRange.value(strFmt(‘((%1 == %2) || ((%1 == %3) && (%4 == "%5")))’, fieldStr(InventTable, ItemType), any2int(ItemType::Service), any2int(ItemType::Item), fieldStr(InventTable, … Continue Reading
Channel9 : X++ into .Net
I accidentally found this interesting video about future architecture where you can run X++ in .Net. http://channel9.msdn.com/posts/Charles/Peter-Villadsen-and-Gustavo-Plancarte-Inside-Ax-Translator-X-to-MSIL
Belgian Dynamics Community Annual Event 2010
The Belgian Dynamics Community is organizing it’s annual event on the 22nd of April in San Marco Village. On the agenda: Keynote : Babyboomers and Digital Natives- key trends for the next decade (Herman Konings) Breakout Session Dynamics AX: Mobile working and ERP: opportunities and challenges (Finn Pedersen, ExpandiT) Breakout Session Dynamics NAV : Technical … Continue Reading
Test if a configuration key is enabled in X++ code
How do you execute code when a Configuration key is enabled? It is pritty easy. Ax x++ has a build-in function ‘isConfigurationKeyEnabled’, witch you can use to check a configuration key. Small example: if (isConfigurationKeyEnabled(configurationkeynum(AIF))) { // Do something… }if (isConfigurationKeyEnabled(configurationkeynum(AIF))) { // Do something… }
Setting propperties on a FormControl without AutoDeclaration
When you want to set a property of a control on a form without setting the property AutoDeclaration = yes. You can address the control trough the following code, knowing that element is a FormRun-object: element.design().controlName("btnOk").visible(false);element.design().controlName("btnOk").visible(false);
Microsoft Tag
Maybe you have seen strange images like the one below. When you have the ‘Microsoft Tag Reader‘ application, you can read the message/link/vCard/… behind this image. You can also create your own Tag’s at http://tag.microsoft.com.