View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Daniel Bonallack Daniel Bonallack is offline
external usenet poster
 
Posts: 110
Default Enter numbers in closed workbook

I have provided users with a workbook with twenty macros (let's call this
macro.xls).

I would like to understand which macros are being used, and how frequently.
So I have an Excel file on the server called Summary.xls (let's say it is
under L:\Excel Tools\Summary.xls)

In column A, I have "Macro 1", "Macro 2", "Macro 3" etc
In column B, I would like to increment the number upwards by 1, each time
the user runs the relevant macro to completion.

What line of code would I put at the completion of each of my twenty macros,
so that the relevant cell in the closed Excel file increments upwards by one?

Something like (?):
x = ' my relevant macro row in the closed book
z = Workbooks("L:\Excel Tools\Summary.xls").sheets("Sheet1").cells(x,2).va lue
Workbooks("L:\Excel Tools\Summary.xls").sheets("Sheet1").cells(x,2).va lue =
z + 1

This didn't work...

Thanks in advance for any help

regards
Daniel