![]() |
![]() |
|
|||||||
| 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: Apr 2002
Posts: 19
|
First off I would love to give much thanks to Thomas Schreiner, he has been so much help, but I do not want to take all of his time.
I have been working on a project, well a basic and Tom has taken it to new levels I never thought possible. I have a monthly log and need it to do some calculations based on another sheet. Just simple (I think) calculations based on the field being emply or haveing a date. It doesn't matter what is there just if anything is there. example: sheet 1 column A name Column B Date The other worksheet: If column B is written in add one to the total if not ignore I now know I know less than before. The more functions I try, the worse everything gets. I may just stick to SUM(a1:b2) that is a sure calculation. Thanks Mike |
|
|
|
|
|
#2 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Monterrey, Mexico
Posts: 1,433
|
I am not sure exactly what you want, but you can edit the following to fit your situation:
Private Sub Worksheet_Change(ByVal Target As Range) If Target <> "" Then Total = Total + 1 Worksheets("Sheet1").Range("A1").Value = Worksheets("Sheet1").Range("A1").Value + 1 End Sub Put this code in the code for the worksheet that will be added on to. The code will add "1" to Cell A1 on Sheet1 everytime a cell is changed and not blank.
__________________
Kind regards, Al Chara |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|