alfredgomez
New Member
- Joined
- Sep 21, 2022
- Messages
- 6
- Office Version
- 2021
- Platform
- Windows
I have a multi-sheet workbook (.xlsm). The 1st sheet is a master sheet, editable, and contains all the data.
The other sheets (Classroom #) are subsets of the master based on which classroom the students are assigned to.
Basically, via individual formula's in the classroom sheets, I was able to copy the student information over to each individual classroom sheet based on the students assigned to the classroom.
The problem is that there are gaps on the classroom sheets where the other classroom students on the master were.
I need to use vba code to
- Select a range on the master sheet (B9:Q83)
- Loop through each row in the range
- Check the classroom value, Cell Q, of currently indexed row in the range.
- Based on the value of Cell Q above, copy range B through P of indexed row, to the appropriate classroom sheet starting from cell B9 of the classroom sheet so that there are no gaps.
- Classroom sheets are numbered (1,2,4,5,7,X).
- Classroom X denotes the student withdrew from the program so they should be skipped.
I tried to figure this out using the many sample vba programs on your site but have become overwhelmed by just trying to understand the code and how to modify it to suit my needs.
Thank you in advance for all of your help
Alfred Gomez
I.T. Coordinator
YMCA of Paterson
The other sheets (Classroom #) are subsets of the master based on which classroom the students are assigned to.
Basically, via individual formula's in the classroom sheets, I was able to copy the student information over to each individual classroom sheet based on the students assigned to the classroom.
The problem is that there are gaps on the classroom sheets where the other classroom students on the master were.
I need to use vba code to
- Select a range on the master sheet (B9:Q83)
- Loop through each row in the range
- Check the classroom value, Cell Q, of currently indexed row in the range.
- Based on the value of Cell Q above, copy range B through P of indexed row, to the appropriate classroom sheet starting from cell B9 of the classroom sheet so that there are no gaps.
- Classroom sheets are numbered (1,2,4,5,7,X).
- Classroom X denotes the student withdrew from the program so they should be skipped.
I tried to figure this out using the many sample vba programs on your site but have become overwhelmed by just trying to understand the code and how to modify it to suit my needs.
Thank you in advance for all of your help
Alfred Gomez
I.T. Coordinator
YMCA of Paterson