I have this line of code in a vba project:

Application.Run Copyrowsandpaste(Worksheets("wobid"), Worksheets("res"), "S", "Completed")
I get the error: "Compile error: Expected Fuction or variable" and it highlights the Copyrowsandpaste portion.

Any ideas why? Copyrowsandpaste is a custom sub I made

Thanks