Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The below works - but is there a better way? It seems that I had to add the
..select to make it work regardless on sheet was previously active - then I forced another worksheet to be active. Sub AddNewWeek() Dim LastRow As Long shtGraphData.Select With Sheets("Graph_Data") If Range("Z6").Value Range("Z5").Value Then LastRow = .Cells(.Rows.Count, "K").End(xlUp).Row .Cells(LastRow + 1, "K").Value = Range("Z6").Value .Cells(LastRow, "L").Resize(1, 6).Copy .Cells(LastRow + 1, "L") End If End With shtInput.Select End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
VBA: Column Select then Data Select then return to cell A1 | Excel Discussion (Misc queries) | |||
Macro to select cells without a certain value and select a menu it | Excel Worksheet Functions | |||
error - select method failed - (columns.select) | Excel Programming | |||
End Select without Select Case, Block If without End If errors | Excel Programming | |||
In Excel 2000, How do you select the whole of a worksheet (Select. | Excel Discussion (Misc queries) |