Quote Originally Posted by rrosa1 View Post
by the way my intention is to change the limit from 6 to 5 or 4 since there r some time data change so i need to change that value but it must be less then 6 how can i do that?
Is the change to 4, 5 or 6 for the whole sheet or per group on the sheet? Do you want to ask the user what the limit is each time?




Quote Originally Posted by rrosa1 View Post
but then code did not change the data sheet as needed when i run the macro again can u let me know what mi doing wrong
Well that's a difficult one because I have no idea what 'as needed' is.

I see you put the count in column M before you make changes; do you want this to be after you make changes instead?
Does M3 value represent the total count of 'Weekly' on the whole sheet? If so, before or after changes made?

It would be a good idea to change all instances of If Var < 6 so that they are all the same.