Hi
Below is the code I am using. I open both files, the one I am copyin
to and the one I am coping from. After I run the macro and close bot
files I can only open either file in read only unless I reboot. I a
sure the code has much room for improvement, for I am new at this. An
help will be greatly appreciated.
Ron
Application.ScreenUpdating = False
Dim rRCount As Integer
Dim cRCount As Integer
Dim rSCount As Integer
Dim cSCount As Integer
Dim LoopNo As Integer
rRCount = 15
cRCount = 5
rSCount = 7
cSCount = 4
pass = False
For x = 1 To 19
If pass = True Then
rRCount = 63
cRCount = 5
rSCount = 11
cSCount = 4
pass = False
End If
If x >= 3 Then
cRCount = cRCount - 8
rSCount = rSCount - 4
End If
If x = 17 Then
rRCount = rRCount - 1
End If
If x = 18 Then
rRCount = rRCount - 1
End If
LoopNo = 4
If x = 19 Then
LoopNo = 3
End If
For A = 1 To LoopNo
Windows("Appendix C FFP Off-site Att 3.xls").Activate
Sheets("Base year").Select
Cells(rRCount, cRCount).Select
Selection.Copy
Windows("FFP Rates Off-Site TE B.xls").Activate
Sheets("FFP Base Yr").Select
Cells(rSCount, cSCount).Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone
SkipBlanks:= _
False, Transpose:=False
Application.CutCopyMode = False
rRCount = rRCount + 0
cRCount = cRCount + 2
rSCount = rSCount + 1
cSCount = cSCount + 0
Next A
If x < 2 Then
pass = True
Else
pass = False
End If
rRCount = rRCount + 48
cRCount = cRCount + 0
rSCount = rSCount + 4
cSCount = cSCount + 0
Next x
End Su