Activating Macro

Solved/Closed
Trowa - Jul 7, 2009 at 06:03 AM
 Trowa - Jul 9, 2009 at 08:11 AM
Hello,

I have made a calender which I want to prepare for next year with the press of a button.

Here is the file: https://authentification.site/582501305.html

When I run the macro "JaartalVerhogen", the current year will rise by one. This will change the dayname of each day. According to the dayname the columns change color.

Since I have more than 3 colors, I had to use a complicated VBA code (provided by Aquarelle on this website)
which has been put under ThisWorkbook when looking at the vba codes.

Now my problem: The colors will only change when I have selected the sheet and copy paste a formula in the same cell.

I want the colors to change when the macro "JaartalVerhogen" is fired.

The worksheet calculate event seems to be the solution, but how do I use it in this situation?

Please let me know if something is still unclear.

Best regards,
Trowa

3 responses

rossdavid Posts 185 Registration date Tuesday November 18, 2008 Status Member Last seen August 6, 2010 29
Jul 7, 2009 at 12:34 PM
I would like to help you but i don't understand your language :S
0
I didn't think it would be necessary to understand my language to help me.

Please let me know if you need anything translated?
0
In a bright moment I found the answer:

I used this code:

Sheets("Januari").Range("C5").Formula = Sheets("Januari").Range("C5").Formula

I have altered it into:

Sheets("Januari").Select
Range("C5").Formula = Range("C5").Formula

Case solved
0