I have an Excel workbook with 4 sheets.
- Master Sheet
- test_1
- test_2
- test_3
I want to move the data from Master Sheet to all the other sheets, which I have done by creating a macro. Daily the Master sheet data will be increasing, so how can I accommodate this change in the Macro.
I have pasted my existing code below:
Sub sbCopyRangeToAnotherSheet()
Sheets("Master").Range("B10:M1628").Copy
Sheets("test_1").Activate
Range("B9").Select
ActiveSheet.Paste
Application.CutCopyMode = Flase
End Sub
Sub sbCopyRangeToCRP2()
Sheets("Master").Range("B10:M1628").Copy
Sheets("test_2").Activate
Range("B9").Select
ActiveSheet.Paste
Application.CutCopyMode = Flase
End Sub
Sub sbCopyRangeToCRP3()
Sheets("Master").Range("B10:M1628").Copy
Sheets("test_3").Activate
Range("B9").Select
ActiveSheet.Paste
Application.CutCopyMode = Flase
End Sub
In the above code I mentioned the hard coded range value of Master Sheet which starts from B10 and ends at M1628.
Going forward number of rows increase**(B10 range will remain)** and I don't want to hard code the Range. How can I accomplish this?