Friday, August 31, 2012

How to Add the desired Number of Sheets in Excel with VBA

VBA Macro to Add the desired No.of Sheets in Excel

Sub Add_Shts()
Dim x, Y
x = InputBox("Enter The No.Of Sheets To Insert :")
For Y = 1 To x
Sheets.ADD
Next Y
End Sub

Note:
This is a very user friendly macro that allows you to add any no.of sheets whose number is increased automatically[sheet1,sheet2,sheet3...Sheetn],even you run a macro for 'n' no.of times.

No comments:

Post a Comment

Hi User, Thank You for visiting My Blog. Please post your genuine Feedback or comments only related to this Blog Posts. Please do not post any Spam comments or Advertising kind of comments which will be Ignored.

Featured Post from this Blog

How to compare Current Snapshot Data with Previous Snapshot in Power BI

How to Dynamically compare two Snapshots Data in Power BI Scenario: Suppose, we have a sample Sales data, which is stored with Monthly Snaps...

Popular Posts from this Blog