Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I know that I did something wrong but I don't know what it is. The error
occurs on the second line of code. Any help will be appreciated. Thanks. Set goalWS = Worksheets("AAV Goals Update Tables") goalWS.Range(Cells(cRow, cCol)) = c1 |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
You don't need the Range() function. Cells() already give you the range:
Sub dural() Dim goalWS As Worksheet Dim c1 As Integer, cRow As Integer, cCol As Integer cRow = 1 cCol = 1 c1 = 1 Set goalWS = Worksheets("AAV Goals Update Tables") goalWS.Cells(cRow, cCol) = c1 End Sub will work just fine. -- Gary''s Student - gsnu200902 "Ayo" wrote: I know that I did something wrong but I don't know what it is. The error occurs on the second line of code. Any help will be appreciated. Thanks. Set goalWS = Worksheets("AAV Goals Update Tables") goalWS.Range(Cells(cRow, cCol)) = c1 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Run-time error '1004': Method 'Range' of object '_Worksheet'failed... again! | Excel Programming | |||
Run-time error '1004': Method 'Range' of object '_Worksheet' failed | Excel Programming | |||
Run-time error '1004': Insert method of Range class failed | Excel Programming | |||
Run-time error '1004' PasteSpecial Method of Range Class Failed | Excel Programming |