How to rename the sheet using macros

Sub ChangeSheetName(SheetOldName As String, SheetNewName As String)
Sheets(SheetOldName).Name = SheetNewName
End Sub
i was using this vba code to change the sheet name any suggestion other than this code please.

in my project this formula is not applicable for few states excel sheets .

need another way do to this.

my sheet name will be changing always and it is not dynamic

1 Like

Hi

Have a view on this thread for more ideas

There is another option or custom component
Have a view on this

Cheers @Gayathri_Mk

1 Like

without using bala reva activities I need,the above you provided did not worked for me,any other approach please

@Gayathri_Mk

Check below thread for your reference

Hope this will help you

Thanks