Need help to develop a script to copy new row of data based on cell value

13 views
Skip to first unread message

Jabez

unread,
Oct 13, 2021, 3:24:49 PM10/13/21
to Google Apps Script Community
Hi,

Have a challenge that am working on at the moment. I have three sheets i.e. Requisitions, Petty Cash and Bank. On the Requisitions sheet i have cash requests from staff, while the Petty cash and Bank sheets records the petty cash and bank transactions. 


What i want to accomplish is as follow;
When the "Approval Decision" cell is changed to Approved, i want it to trigger copying the row as follows.

In the requisition sheet, 
  • If the "Expense Category" is "Bank" then should copy the Request time, Expense Type and Requested Amount to respective fields in the "Bank" sheet.
  • If the "Expense Category" is "Petty Cash", then should check if the "Other Expense Details Types" column is "Petty Cash Refill". If true then should copy the 
      • Request Time to Date in Petty Cash sheet,  
      • Expense Type to Details in Petty Cash sheet
      • Requested Amount to Cash In, in the Petty Cash Sheet.
    • Otherwise, should just copy the data same way as indicated above except that the Requested Amount will now be copied to the Cash Out column.
Many thanks in advance for your support. 
Reply all
Reply to author
Forward
0 new messages