Hi,
You just need to find a unused cell near by, and use it as a recorder.
If the unused cell is, say, E1, then your macro would look like this:
Sub resetval_SCRUSH()
Range("d1") = "0"
Range("E1") = Range("E1") + 1
End Sub
You may need to start by putting 0 (zero) into E1, but try without first.
Hope this helps.
Regards - Dave.
> Date: Wed, 15 Jul 2009 09:58:07 -0700
> Subject: $$Excel-Macros$$ Count the number of times Macro ran - Urgent
> Question
> From: [email protected]
> To: [email protected]
>
>
> Hello,
>
> A newbie here and I think this should be really easy for others....I
> have a macro which reset cell value to "0" and I have created a text
> box and assign this macro to it. So everytime I click that box it
> resets D1 value to "0".
>
> I just want to have a count the number of times macro -
> RESETVAL_SCRUSH ran...
>
> Sub resetval_SCRUSH()
> Range("d1") = "0"
> End Sub
>
> thx in advance/
>
> >
_________________________________________________________________
View photos of singles in your area Click Here
http://dating.ninemsn.com.au/search/search.aspx?exec=go&tp=q&gc=2&tr=1&lage=18&uage=55&cl=14&sl=0&dist=50&po=1&do=2&trackingid=1046138&r2s=1&_t=773166090&_r=WLM_EndText
--~--~---------~--~----~------------~-------~--~----~
----------------------------------------------------------------------------------
Some important links for excel users:
1. Excel and VBA Tutorials(Video and Text), Free add-ins downloads at
http://www.excelitems.com
2. Excel tutorials at http://www.excel-macros.blogspot.com
3. Learn VBA Macros at http://www.vbamacros.blogspot.com
4. Excel Tips and Tricks at http://exceldailytip.blogspot.com
To post to this group, send email to [email protected]
If you find any spam message in the group, please send an email to:
Ayush Jain @ [email protected] or
Ashish Jain @ [email protected]
<><><><><><><><><><><><><><><><><><><><><><>
HELP US GROW !!
We reach over 5,000 subscribers worldwide and receive many nice notes about the
learning and support from the group. Our goal is to have 10,000 subscribers by
the end of 2009. Let friends and co-workers know they can subscribe to group at
http://groups.google.com/group/excel-macros/subscribe
-~----------~----~----~----~------~----~------~--~---