Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Greg
 
Posts: n/a
Default 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
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips
 
Posts: n/a
Default 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



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Greg
 
Posts: n/a
Default 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




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
When I open a workbook, another one called Book1 is also opened. W Ian@MarlandLtd Excel Discussion (Misc queries) 2 November 9th 05 09:36 AM
Links only update when external workbook is open CMB Excel Worksheet Functions 6 November 8th 05 12:39 AM
Calc status of open excel workbook should not overwrite another Michael Hill Setting up and Configuration of Excel 1 October 28th 05 06:48 PM
Importing Data from unopened Workbook into an open Workbook GrayesGhost Excel Discussion (Misc queries) 0 March 5th 05 11:25 PM
Sumif Linking to Another Workbook error #VALUE! Tunde Excel Discussion (Misc queries) 16 March 4th 05 03:02 AM


All times are GMT +1. The time now is 06:21 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"