Results 1 to 5 of 5

Combo Box (Form Control) With Macro On A Graph Sheet

Threaded View

  1. #2
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,480

    Re: Combo Box (Form Control) With Macro On A Graph Sheet

    Has to be a Form control, ActiveX controls are not supported, on chart sheets.

    Assign a macro to the combo box and within it determnine the action to take based on the value.
    This is for an combo with 3 list items.

    Sub DropDown1_Change()
    
        Dim shpTemp As Shape
        
        Set shpTemp = ActiveSheet.Shapes(Application.Caller)
        Select Case shpTemp.ControlFormat.Value
        Case 1
            MsgBox "You chose " & shpTemp.ControlFormat.List(1)
        Case 2
            MsgBox "You chose " & shpTemp.ControlFormat.List(3)
        Case 3
            MsgBox "You chose " & shpTemp.ControlFormat.List(2)
        End Select
    End Sub
    Attached Files Attached Files
    Cheers
    Andy
    www.andypope.info

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1