I have 20+ sheets with the same structure and I am trying to make a summarization on the first sheet. The issue I am facing is that I am a complete rookie when it comes to how to use vba.
The code below is what I thought was the first step, all the cells from A2:A31
in blad5 should retain the background color into blad1 E2:E31
, if I change the color in blad5 it would show take color on blad1 (All the cells in Blad5 A2:A31
have a green background color)
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Worksheets(Blad2).Range("A2:A31").Interior.Color = Worksheets(Blad1).Range("E2:E31").Interior.Color
End Sub
My intention is to utilize a do loop over all the sheets (blad2-blad27) to blad1 which is my summarization sheet.
Would be grateful for a nudge in the right direction on how to do a function en do loop for the sheets (minus blad1 / sheet1) and how to properly write the interior.color
macro.
With kind regards, Fredrik