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.

Monday, March 7, 2011

How to copy Advance query for other users, that is created by one user

Many a times we came accross an issue. for any report or form, when we make a complex query to display the records we have to enter the same ranges and criterias for all the users.
Here is the code by which you can just copy the query for all the other users. This will copy all advance queries created by from user.

static void advanceFilterQueries(Args _args)
{
SysLastValue sysLastValue;
UserId fromUserId, toUserId;
;

fromUserId = "user1"; // Enter ID of the user from where to copy
toUserId = "user2"; // Enter ID of the user where you want to copy
while select sysLastValue
where sysLastValue.recordType == UtilElementType::UserSetupQuery
&& sysLastValue.UserId == fromUserId
{
sysLastValue.UserId = toUserId;
sysLastValue.RecId = 0;
sysLastValue.insert();
}
}