|
Question : Export Worksheets with Values and additional Code for Cell Protection
|
|
I have a main workbook that has 30 - 35 worksheets. The initial values are generated based upon a formula within the workbook. In some cases this generates a #VALUE after copying the worksheet to a second one that is sent out to the appropriate department for them to enter their budget numbers.
I would like to export the worksheets with the institution calculated "values" for each department, and since those values should not be changed, to add cell protection, for each Worksheet exported.
There are three areas that have the "Values" that are derived from the workbook formulas. These are B10:M13, B26:M31, and B43:M45.
The other formulas that sum the user input values are in B34:M34 and N24:N34, and it is preferred that they stay intact, as it becomes the worksheet for each department.
Any help would be appreciated,
Cook
|
|
Answer : Export Worksheets with Values and additional Code for Cell Protection
|
|
Cook, Did you notice the following two statements in the code?
For Each ws In ActiveWorkbook.Worksheets 'Loop through every worksheet If ws.Visible = xlSheetVisible Then 'But only export them if they are visible
Brad
|
|
|
|