put following code on class method
void initFromArgs(Args args)
{
;
if (args && args.dataset() == tablenum(abcform))
{
abcForm = args.record();
salesOrder = abcForm.SalesId;
qty = abcForm.Qty;
}
}
then you can call this method to main method.