Hi Mohan,
Welcome to ExcelFox !!!
may be..
Code:Dim chtSelected As Chart On Error Resume Next Set chtSelected = ActiveChart On Error GoTo 0 If chtSelected Is Nothing Then MsgBox "No chart selected", vbInformation Else MsgBox chtSelected.Name End If
Hi Mohan,
Welcome to ExcelFox !!!
may be..
Code:Dim chtSelected As Chart On Error Resume Next Set chtSelected = ActiveChart On Error GoTo 0 If chtSelected Is Nothing Then MsgBox "No chart selected", vbInformation Else MsgBox chtSelected.Name End If
Cheers !
Excel Range to BBCode Table
Use Social Networking Tools If You Like the Answers !
Message to Cross Posters
@ Home - Office 2010/2013/2016 on Win 10 (64 bit); @ Work - Office 2016 on Win 10 (64 bit)
Bookmarks