I'm trying to add a disclaimer at the bottom of a set of data and I am having trouble getting it to work properly.
I want this disclaimer to get added to all sheets in the workbook except for two. The two sheets that are excluded are user input sheets that generate the other sheets using another macro that does work.
Here's my code:
Sub disclaimer()
Application.ScreenUpdating = False
Dim ws As Worksheet
Dim N As Long
For Each ws In Sheets
If ws.Name <> "Sheet1" And ws.Name <> "Sheet2" Then
N = Cells(Rows.Count, "A").End(xlUp).Row + 1
Cells(N, "A") = "This report is confidential and for use between CompanyName and the Salesperson only. It is not to be disclosed to any other third party."
End If
Next ws
Application.ScreenUpdating = True
End Sub
I inserted it into the macro that creates these sheets using the "Call" command at the end of the macro. When I run it, the text was inserted where I wanted it to go at the bottom of the data set, however, it wasn't merged and I wanted to shrink the font size to size 10. The disclaimer needs to be merged and centered across columns A to E and is long enough that it will need to be merged with two rows.
Is there a way to do this?
Bookmarks