How to count the number of lines which are customized in USR layer so that we can compare it with SYS layer.
Is there any tool or any procedure to count the number of lines in the various objects(Tables,Classes,Reports,Forms).
Please share your comments if anyone is having any idea.
Number of lines is a bit tricky topic, because it can mean different things. Maybe you want to exclude comments, maybe you don’t want to count lines copied from lower layers, maybe you want to include things like form designs because they also increase complexity, maybe you want to exclude them because you are interested in code only…
The easiest way is just count lines in .xpo files, more complex scenarios would use reflection (e.g. to count selected TreeNode types only).
You can try this tool for complexity measurements, in AX2012 you can also take a look at SysStartupCmdUpdateMetrics (it seems not to be intended for public use so it’s not very user friendly - let me know if you need details about it).
Is there any way that we can count total number of lines in the whole AOT (Classes, Tables, Reports, Forms) no matter it is USR layer or any other layer.
Everything is possible, but it depends on what you want to achieve, as I mentioned before. You can, say, export all objects to one big .xpo and count its lines, if this is what you really want to count.
Everything is possible, but it depends on what exactly you want to achieve, as I mentioned before. You can, say, export all object to one big .xpo and count its lines, if this is really what you want to measure.
I want to count the total number of lines of codes in AOT no matter in which layer it is.
I have tried the link which you have sent it not that much helpfull.
We need this in Ax2009, mentioned class in not in Ax2009
Martin clearly mentioned that this class is in DAX 2012. You should at least read replies thoroughly [:)]
And again as Martin says if you are looking for a simple count, just export AOT into XPO and count the lines.
Last but not least, have a look here (http://insidedynamicsax.blogspot.com/2011/01/dynamics-ax-counting-lines-of-code.html) and see whether this helps.