Auto Fill from CRM to Creator field
Hello,
I have a CRM field on my creator app (Sales Order No.). The user can select the created SO from CRM while using creator to enter records, and another CRM field which will be auto filled with account name related to the SO number chosen by user.
I need to keep the last selected Sales Order # and the Account name, so the user doesn't need to re-select the same value incase entering multiple records for the same SO/Account.
I'm using below code:
on user input:
crmresp = zoho.crm.getRecordById("SalesOrders" ,input.Sales_Order_No_ID ) ;
Account_Name = crmresp.get(("Account Name")) ;
on Load:
lastRecord = Field_Jobs[ID != 0] sort by Added_Time ;
Sales_Order_No_ID = lastRecord.Sales_Order_No_ID ;
Sales_Order_No = lastRecord.Sales_Order_No ;
Account_Name = lastRecord.Account_Name ;
However when I submit a new record it saves the first record I created since I created the App, it doesn't select the last SO submitted,
I hope I made it clear. Anyone can help with that?
Thanks,