fazilps

06-19-2014, 06:55 PM

I have a sample data set like what I have at work. The file is attached.

The number of orders assisgned needs to be balanced. As in the sample data, some of the orders are already assisgned to a team.

Range J15:L27 determines how many orders have been already assisgned and how many more can be allocated.

What I would require the macros to do is start filling up Column C if it is blank, with the Team Name depending on which which WorkGroup is in column B.

I figured it could be done with one or two loops.

If L16 >0, find the next blank next to Workgroup1 and put "Team A". If L16 =0, move to next team member. Repeat till "To Be Assigned" for each member is 0 or no more orders remaining to be assigned.

I'm not an advanced VBA user, just know the basics. Any help would be highly appreciated.

Thanks in advance.

The number of orders assisgned needs to be balanced. As in the sample data, some of the orders are already assisgned to a team.

Range J15:L27 determines how many orders have been already assisgned and how many more can be allocated.

What I would require the macros to do is start filling up Column C if it is blank, with the Team Name depending on which which WorkGroup is in column B.

I figured it could be done with one or two loops.

If L16 >0, find the next blank next to Workgroup1 and put "Team A". If L16 =0, move to next team member. Repeat till "To Be Assigned" for each member is 0 or no more orders remaining to be assigned.

I'm not an advanced VBA user, just know the basics. Any help would be highly appreciated.

Thanks in advance.