How do I add one to a number everytime I open the same workbook
I have a cell number like 1001 and I want it to add to 1002 the next time I
open ithe workbook and 1003 the next time and so on Thanks Greg |
How do I add one to a number everytime I open the same workbook
Private Sub Workbook_Open()
With Worksheets("Sheet1").Range("A1") .Value = .Value + 1 End With End Sub 'This is workbook event code. 'To input this code, right click on the Excel icon on the worksheet '(or next to the File menu if you maximise your workbooks), 'select View Code from the menu, and paste the code -- HTH RP (remove nothere from the email address if mailing direct) "Greg" wrote in message ... I have a cell number like 1001 and I want it to add to 1002 the next time I open ithe workbook and 1003 the next time and so on Thanks Greg |
How do I add one to a number everytime I open the same workboo
Thanks so Very Much
God Bless Greg "Bob Phillips" wrote: Private Sub Workbook_Open() With Worksheets("Sheet1").Range("A1") .Value = .Value + 1 End With End Sub 'This is workbook event code. 'To input this code, right click on the Excel icon on the worksheet '(or next to the File menu if you maximise your workbooks), 'select View Code from the menu, and paste the code -- HTH RP (remove nothere from the email address if mailing direct) "Greg" wrote in message ... I have a cell number like 1001 and I want it to add to 1002 the next time I open ithe workbook and 1003 the next time and so on Thanks Greg |
All times are GMT +1. The time now is 02:31 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com