Hello All,
I tried iterating over the datasource records just like the below code snippet shows.
InventTrans localInventTrans = InventTrans_DS.getFirst() as InventTrans; ItemId itemId; while(localInventTrans) { //access fields by using localInventTrans.fieldname itemId = localInventTrans.ItemId; //get the next record from the datasource localInventTrans = InventTrans_DS.getNext() as InventTrans; }
but the problem is the records are being fetched in reverse, for example:
if the datasource had three records with ids 1,2 and 3. The ds_.getFirst() returns the last id record ( in this case id=3) and then traverses back.
Is there any way I can change this behavior and traverse from the actual first record ( in this case id=1).
Thanks.