Showing posts with label Dynamics AX 2009. Show all posts
Showing posts with label Dynamics AX 2009. Show all posts

Friday, March 18, 2011

Dynamics AX 2009 Financials Training Videos

I've come accross some training materials related to financials in Dynamics AX 2009. It is shared by one of my friend. Here is the link of those videos

https://cid-1613f1612d4c9e73.office.live.com/viewpermissions.aspx/Public/Financial%20Videos?ref=1

Enjoy daxing :)
Surely, you will find them really worth watching.

Sunday, May 23, 2010

Random and Sequence number Generation in AX

Ax provides us with two classes for this purpose. I am just giving an example on how to create random numbers and numbers in sequence by using them.

Random numbers:
static void RandomNumbers(Args _args)
{
RandomGenerate RandomRange = new RandomGenerate();
Random Random = new Random();
;
//This generates random numbers within the given range
info(int2Str(RandomRange.randomInt(20,100)));

//This generates random numbers
info(int2Str(Random.nextInt()));
}

Numbers generated can be repeated. So you should make some explicit validations if unique number is required.

Sequence numbers:

static void Sequence(Args _args)
{
Sequence Seq = new Sequence("Sequence",8,100,500,1);
// Displays the current value of the object
print Seq.currval();
while(1)
{
print Seq.nextval(10);
pause;
}
}
Sequence class takes the following parameters:
SequenceName ('Sequence') = It can be any string.
Identification No ('8') = Identification number for the sequence.
Initial Value ('100') = Initial value.
Maximum value ('500') = Maximum value.
Flag('1') = It indicates whether the cycle should repeat after maximum value.

The method “nextVal” takes the value to be incremented for next number as parameter.