Wednesday, March 28, 2007

My first attempts in Dynamics AX 4.0 SP1

Last week I started trying out what is Dynamics AX 4.0 SP1 European Version (Russian Localization included), creating a project for data import using ODBC connection (from an external SQL database).

In the process, I decided to take note of what I like in the new release, and also write down any bugs I find so that someone can send them over to Microsoft to be fixed.
(this is compared to Dynamics AX 3.0 SP3, but also tried out in Dynamics AX SP5 KR2)

Here is the small list I got so far:
New features:
  1. When pressing Enter to go to the next line in the X++ Code Editor window, the cursor is automatically positioned on the same column as the previous line. This was also present in DAX 3.0, but only after 2 lines are positioned in the same way (when adding a lot of conditions in the where clause, for example). But, there is a small 'bug' here. If you put the cursor at the end of a line of code, press Enter, the cursor will automatically get positioned under the line. Press Tab to indent one time. And then hit Enter again. The cursor is supposed to be directly under the line in the same column. But instead, it is position in the first column of the next line.
  2. When exporting any object to an .xpo file, the file gets a friendlier name, prefixed with the type of object that is being exported. For example, if you export the InventTable form, the file name would be 'Form_InventTable.xpo', which is pretty cool and helps to find the needed xpo file easier later.
  3. The Hot Keys for the Dynamics Debugger have been changed from F7, F8 to F10, F11. This is very inconvenient at first. And not just because you have to press different keys now. But because the F7 key actions were moved to F11, and F8 - to F10. By now I was used that the left key would take me deaper into the implementation. now it's vise versa.

And here is the bug list (some of them might have been fixed by now, or moved to the Known Issues, but I am unaware of this, sorry):

  1. The multiline comments are not colored correctly. The first slash is black, if the multiline comment spreads over more that one line. The rest of the comment is green, as it should be.
  2. In the table browser form, the UPDATE_RECORDSET command crashes Dynamics AX.
  3. After compiling a project, some of the tables in it are marked as DIRTY (red line near the name). This does not happen to all of the tables, but to those that it does, it happens all the time. Walkthrough: select a table in the AOT, compile it. (no changed done to the table). Then, compile the project. The previously selected table is marked in red. also, one of the tables in my project is always marked dirty after compilation.

That's all I have stumbled upon so far. And I am pretty sure more is to come. ;)

Friday, March 23, 2007

MorphX IT by Steen Andreasen in Russian is available for sale

The book on Dynamics AX development MorphX IT is finally out for sale.
So far there is only one location you can purchase it from (only paperback edition):

I am still trying to find a Print on Demand service based in Moscow or Kiev, but no luck so far.

If you have any questions or suggestions regarding the book, feel free to e-mail me or post a comment here.

Here is information on delivery costs (for Kiev, Ukraine):

economy - $10.81
standart - $17.50
express - $26.09

Friday, March 16, 2007

AxCreateNewProject version 1.3.2 released

Updated the project for creating projects ;) to version 1.3.2

Download link

Change log:
  • When a project is updated, or "duplicated", the project settings are not stored, so that the node selections and project name & prefix are as they were last time the project was actually created. Most of the developers have a fixed project prefix and name, and layout. But sometimes, rarely we have to modify the layout. Then, when we need to create another project, we have to reset the settings to the stardard layout we used. Well, now we do not have to do it outselves.
  • The "Copy Objects" button is always visible now, only disabled when not needed - this is done to promote the using of this feature, as I gather that most devs don't even know that it exists. :)
  • MenuItemButton text has been modified to show the behaviour when pressing Ctrl (updating a project)
  • Another project group node was added to the dialog - More... This group node contains the rest of the Data Dictionary Nodes. By default, it is collapsed, because rarely used. The rest of the AOT nodes (SystemDocumentation nodes) will not be included.

Also, the tutorial on MultiSelect options has been updated slightly, giving the opportunity to test Set(Types::Record) and InventTable.setTmp(). See homepage for details.

Tuesday, March 06, 2007

Dynamics AX Tutorials (continued)

Hello, readers.

After posting the first AX tutorial about Multiple Selection options in Dynamics AX we had a very interesting discussion about what's best to use in DAX at
After this discussion, I decided to dig into the issue some more and see for myself, what is the best choice here.

So I modified the previous project a little bit: (you can download it here)
  • Added a Server-Based class that does all the processing of selected lines
  • Added a temporary table, tmpInventTable, consisting only of one field, ItemId.
  • Added a job - an approximate way to determine the memory wastes for filling different types of objects.
  • Added 2 tab pages to the form, so the form now allows five tipes of processing:
    • Using a Set
    • Using a Set (the query uses a JOIN)
    • Using a Temporary Table
    • Using a Temporary Table (the query uses a JOIN)
    • Using standard DAX way with multiselecting records

The good thing is that now everyone can try out the different options and choose what is most appropriate for his specific needs.

After this, I also did a test run on a 3-tier installation and on a 2-tier installation.

Here are the Memory test results: (the first is in 2-tier, the second - in 3-tier configuration)

Here are the Processing test results: (the first is in 2-tier, the second - in 3-tier configuration)

The results of my tests can also be found at the homepage of this tutorial.

As you can see from the results, the 3-tier environment provides more balanced results. And in 2-tier I got 25 to 60!!! times increase on Processing tests when not using joins. I would love to know what your resuls will be.

Filling in data is also slightly slower when using Temporary Tables, but the difference is not that great, especially if you take into consideration the amount of records inserted into it (up to 100 000)

You comments and suggestions are very welcome.

Monday, March 05, 2007

AxPromptDBSync - a simple project that allows to choose whether to synchronize the AOT with the database at the moment or not.

This should be used with extreme caution and only by experienced developers (people, who know what they are doing)

Get the tool at axaptapedia

Someone may ask - why would I need to prevent syncronization? Isn't it what should be done at all times?
And the answer is, of course, YES.

But just stop for a minute and remember the amount of time you have to wait till syncronization is over after adding just a single EDT or tablefield. Or, what most people do, Break the operation and (if you managed to actually break it) do it for every field being added. Or, which is even better, export the project, modify the xpo file and then import it back into DAX. :) A nice way, no doubt.

Well, here is a small and simple solution. When syncronization is about to begin, a dialog will popup asking if it should continue. If not, the syncronization will not be performed.
Actually, you can specify the exact way the system should behave through your user settings. The 2 checkboxes are added to the SysUserInfo table: one specifies if the syncronization should be performed, the second - if the user should be prompted with a dialog.

My settings are: 1 - not checked (means should go on with Sync), 2 - checked (means the prompt dialog is going to pop up)
This thing really saves a lot of time.