Keith W
01-21-2009, 07:19 PM
Hi,
New member,:friends: fairly new with VBA,:dunno but would appreciate some help on the following:
I have a workbook that contains student reports, up to 50 worksheets are allowed, but not all used.
Some students work with different employers, and what i would like some help with is, does anyone know a way of saving each worksheet as a separate workbook with the title of the worksheet (which is the students name) in a folder which has a name specific to the employers. The students worksheets each have a cell with the employer saved in a cell.
I have managed to be able to write some code which will Identify the employer from the student worksheets and use this as part of a path name to the relevant employer folder, but I dont seem to be able to crack a way of splitting the worksheets into separate workbooks. I have attached a sample of code as to how far I have got so far, but now I need some help to put code where shown.
Incidentally the new workbooks will not have to use any active links after saving although the originals actually do.
Also I need to keep the sheet formatting in the new workbooks.
Hope this is not too much to ask first time up ! Any help would be much appreciated.
Thanks in anticipation.
New member,:friends: fairly new with VBA,:dunno but would appreciate some help on the following:
I have a workbook that contains student reports, up to 50 worksheets are allowed, but not all used.
Some students work with different employers, and what i would like some help with is, does anyone know a way of saving each worksheet as a separate workbook with the title of the worksheet (which is the students name) in a folder which has a name specific to the employers. The students worksheets each have a cell with the employer saved in a cell.
I have managed to be able to write some code which will Identify the employer from the student worksheets and use this as part of a path name to the relevant employer folder, but I dont seem to be able to crack a way of splitting the worksheets into separate workbooks. I have attached a sample of code as to how far I have got so far, but now I need some help to put code where shown.
Incidentally the new workbooks will not have to use any active links after saving although the originals actually do.
Also I need to keep the sheet formatting in the new workbooks.
Hope this is not too much to ask first time up ! Any help would be much appreciated.
Thanks in anticipation.