Using AOT Query Object in X++ Code

Here i posted the code to use the AOT Query Object in our X++ code.
1) Create a AOT Query Object as your requirement.
2) Create a Job and paste the below code to check the Query Object.
static void ExecuteAOTQuery(Args _args)
QueryRun queryRun;
Counter totalRecords;
queryRun = new QueryRun(queryStr(CreatedAOTQueryName));
if (queryRun.prompt())
while (
info(strFmt(“Total Records : %1”, totalRecords));

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.