Hi, I am having trouble to add rows below each employees to show the sum of the salaries for a certain period. I tried using Excel add rows, however I have no idea how to use it. Is there any other way to do it?
I gave a sample below. I would appreciate if someone could assist me adding rows below each employees (James, Jenny & Stephen) showing the total sum for that certain period. I really appreciate any help. Thanks!
Read Excel Data: Use the “Read Range” activity to read the data from the Excel sheet into a DataTable variable.
Calculate the Sum: Iterate through the DataTable to calculate the sum of the salaries for each employee based on the specific period. Store the calculated sum in a separate variable.
Add Rows to Excel: Use the “Write Cell” or “Write Range” activity to add a new row below each employee’s data in the Excel sheet.
Hi, I apologise for bothering. Am I suppose to input everything under the “Calculate the Sums:” that you stated above into 1 assign activity? I am confuse about the calculation part. And regarding the adding rows in the DataTable, how do I do it?
Create variables to store the sums. For example, you can create variables like totalSum1 , totalSum2 , and totalSum3 to hold the sums of three columns.