![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: May 2002
Location: Roger M. Fry
Posts: 1
|
We are racking our brains here trying to design a form in Excel that automatically increments the number (i.e. 5600) by one each time the form is opened. Is there a formula or macro that will accomplish this task?
|
|
|
|
|
|
#2 |
|
Board Regular
Join Date: Apr 2002
Location: Surrey, United Kingdom
Posts: 75
|
Hi,
Do you open your form with a button? If you do you could add the following line: YourForm.Show Nmbr = ActiveSheet.Range("A1").Value ActiveSheet.Range("A1") = Nmbr + 1 Let me know if I've missed the point and your number isn't actually in a cell. Nibbs |
|
|
|
|
|
#3 |
|
Board Regular
Join Date: Mar 2002
Posts: 160
|
Under VBA project, click This Workbook and select Workbook_Open. Put the code in here and each time you open the file the cell should increment.
|
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|