Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The following code is failing on the last line. Has anyone any ideas?
Dim TargetSheet As Worksheet Set TargetSheet = Application.Workbooks("Summary.xls").Worksheets ("Sheet3") 'Add column headings TargetSheet.Range(Cells(1, 1)).Value = "Disease Group" In other posts I have seen people were helped out by qualifying the cells method with the range, but when I substitute the last line with: TargetSheet.Range(TargetSheet.Cells(1, 1)).Value = "Disease Group" it still fails on that line with the same error. Kind regards, John |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Run-time error 1004 Method SaveAS of object _Workbook failed | Excel Programming | |||
Run-time error '1004': Method 'Range' of object '_Global' failed | Excel Programming | |||
Run-time error '1004': Method 'Range' of object '_Global' failed | Excel Programming | |||
Run-time error 1004: Method 'Axes' of object '_chart' failed | Excel Programming | |||
"Run-time error '1004'" Method 'Range' of object '_global' failed. | Excel Programming |