I am trying to automate the following but not sure what code to use for it. In sheets("Data") if any value in column A = Employee then copy the corresponding value in column C and paste in sheets("Report") in col C6 and onwards. Many thanks.
I am trying to automate the following but not sure what code to use for it. In sheets("Data") if any value in column A = Employee then copy the corresponding value in column C and paste in sheets("Report") in col C6 and onwards. Many thanks.
Try this:
![]()
Please Login or Register to view this content.
I got an error saying Method Range of Object worksheet failed and it highlighted this line
"vA = sh1.Range("A", "A" & lr1).Value"
I have attached the sample file along with this message. Basically, I am trying to actomate all the fields in Report tab but was trying to start with EIN in col c of report tab. many thanks.
As I posted it, that line should be:
Note "A1" NOT "A"![]()
Please Login or Register to view this content.
wow. that worked beautifully. Thanks. Any idea how i could populate the vacation hours and overtime hours in the report tab.
From the workbook you posted, it's not clear that you have set up the Data sheet in a way that makes finding vacation and O/T hours consistent from one employee to the next. If you revise that sheet so that each Employee record contains those quantities (even if they are zero), the code I posted can be easily adapted to do this.
unfortunately this is how the data is pulled from the system and there will be multiple data extracts which is why I am attempting to automate. Is there any way to say if there is employee totals in A col then copy data from E col and paste in E col of report tab?
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks