//Create Runable class in Dynamics 365 for finance and operations
class SSLRunClassTest
{
public static void main(Args _args)
{
Query query;
QueryBuildDataSource qbds;
QueryRun queryRun;
ProjTable projTable;
query = new Query();
qbds = query.addDataSource(tableNum(ProjTable));
qbds.addSortField(fieldNum(ProjTable, Name),SortOrder::Ascending);
qbds.addRange(fieldNum(ProjTable,Type)).value(queryValue(1);
queryRun = new QueryRun(query);
while (queryRun.next())
{
projTable = queryRun.get(tableNum(ProjTable));
info(strFmt("%1, %2, %3",projTable.ProjId,projTable.Name,projTable.Type));
}
}
}
class SSLRunClassTest
{
public static void main(Args _args)
{
Query query;
QueryBuildDataSource qbds;
QueryRun queryRun;
ProjTable projTable;
query = new Query();
qbds = query.addDataSource(tableNum(ProjTable));
qbds.addSortField(fieldNum(ProjTable, Name),SortOrder::Ascending);
qbds.addRange(fieldNum(ProjTable,Type)).value(queryValue(1);
queryRun = new QueryRun(query);
while (queryRun.next())
{
projTable = queryRun.get(tableNum(ProjTable));
info(strFmt("%1, %2, %3",projTable.ProjId,projTable.Name,projTable.Type));
}
}
}
No comments:
Post a Comment