First, naming your sub FileCopy is probably a bad idea.
There's a FileCopy statement in VBA that could cause confusion--maybe not with
excel--but it sure would confuse me. I'd rename it.
I didn't test this, but I'd try this sort of code:
Sub myFileCopy()
Worksheets("Lookup").Range("C2").PasteSpecial _
Paste:=xlPasteValues, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
Worksheets("Staff_report").Range("A1").PasteSpecial _
Paste:=xlPasteValues, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
Worksheets("Staff_report").Range("A50").PasteSpecial _
Paste:=xlPasteValues, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
Worksheets("Staff_report").Range("A100").PasteSpecial _
Paste:=xlPasteValues, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
Worksheets("Staff_report").Range("A150").PasteSpecial _
Paste:=xlPasteValues, Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
'rest of your original code here.
End Sub
And yes, you can unprotect a workbook, display the worksheet, run the macro,
hide the sheet, reprotect the workbook.
Option Explicit
Sub testme02()
Dim myVisibility As Long
Dim myPWD As String
myPWD = "asdf"
With Workbooks("book1.xls")
.Unprotect Password:=myPWD
myVisibility = .Worksheets("Lookup").Visible
.Worksheets("lookup").Visible = xlSheetVisible
'do the work
MsgBox "do the work!"
.Worksheets("lookup").Visible = myVisibility
.Protect Password:=myPWD
End With
End Sub
(You could get most of this code by recording a macro when you do this
manually.)
But most of the time, there isn't a reason to do things this way. I think most
people find the:
worksheets("Lookup").select
range("a1").select
selection.pastespecial....
much more difficult to read/debug than:
worksheets("lookup").range("a1").pastespecial...