![]() |
Inserting data into next blank cell down in next sheet
I am trying to make a 2 sheet workbook which has the input details in Sheet1
A1 and this is changed weekly but the info in this cell should then be inserted into the first blank cell in Column A in Sheet 2. I have tried this code (below) but it doesn't seem to work and maybe I am doing something wrong. Could someone let me know if this code should work for this purpose or is there another code I could try? Code used at present: Sub copytonextsheet() With Sheets("Sheet2") n = .Cells(Rows.Count, "A").End(xlUp).Row + 1 ..Cells(n, "A").Resize(, 4).Value = _ Cells(1, "A").Resize(, 4).Value End With End Sub Thanks Nick |
Inserting data into next blank cell down in next sheet
Delete a dot at the beginning of this line:
...Cells(n, "A").Resize(, 4).Value -- Wigi http://www.wimgielis.be = Excel/VBA, soccer and music "Nick Wakeham" wrote: I am trying to make a 2 sheet workbook which has the input details in Sheet1 A1 and this is changed weekly but the info in this cell should then be inserted into the first blank cell in Column A in Sheet 2. I have tried this code (below) but it doesn't seem to work and maybe I am doing something wrong. Could someone let me know if this code should work for this purpose or is there another code I could try? Code used at present: Sub copytonextsheet() With Sheets("Sheet2") n = .Cells(Rows.Count, "A").End(xlUp).Row + 1 ..Cells(n, "A").Resize(, 4).Value = _ Cells(1, "A").Resize(, 4).Value End With End Sub Thanks Nick |
Inserting data into next blank cell down in next sheet
Sorry, that was my fault - there is only one dot there - I must have typed
another in. But that code doesn't work Nick "Wigi" wrote in message ... Delete a dot at the beginning of this line: ..Cells(n, "A").Resize(, 4).Value -- Wigi http://www.wimgielis.be = Excel/VBA, soccer and music "Nick Wakeham" wrote: I am trying to make a 2 sheet workbook which has the input details in Sheet1 A1 and this is changed weekly but the info in this cell should then be inserted into the first blank cell in Column A in Sheet 2. I have tried this code (below) but it doesn't seem to work and maybe I am doing something wrong. Could someone let me know if this code should work for this purpose or is there another code I could try? Code used at present: Sub copytonextsheet() With Sheets("Sheet2") n = .Cells(Rows.Count, "A").End(xlUp).Row + 1 ..Cells(n, "A").Resize(, 4).Value = _ Cells(1, "A").Resize(, 4).Value End With End Sub Thanks Nick |
All times are GMT +1. The time now is 01:51 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com