automate a variable number of rows to copy to different worksheet with same header

  • Hi, i've been searching for days on how to get something in excel automated, and sor far everything I found and tryed did not work. can someone help me or direct me to a solution.


    I have to deal with a master worksheet that list multiple site, I must copy each site to a different sheet, with the same header. I'm still learning about VBA and I'm not there yet.


    in the template you can see what i'm trying to get: (colors are only indications on what must be in different sheets)


    -in the master sheet:
    -the first 6 rows (in yellow) must be copied to every sheet created (A1:I6)
    -the other rows to copy from the master is variable (sometimes more and less)
    -the only thing that is constant is the rows with "VENTES" in colum A
    -I need to get from the row before "VENTES" to the second row before the next "VENTES" (ex. A8:I85 ; A86:I125)
    -the sheet name must be the same as the row before "VENTES" (ex: tab Neiges, MR)

    -so on, and so on. (variable number of times).


    Hope that I explained well and that someone can help, Thank you.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!