AnsweredAssumed Answered

VBA button in normal.mxt vs project.mxd

Question asked by geonetadmin on Sep 24, 2010
Latest reply on Apr 19, 2011 by lledsmith
Original User: alnesbit

Hi all,

I wanted to put code in the normal.mxt instead of the mxd but it doesn't work. The code just launches a toolbar that I created. Why doesn't this work in the normal.mxt?

Private Sub UIButtonControl9_Click()

    Dim pCmdBars As ICommandBars
    Set pCmdBars = ThisDocument.CommandBars
    Dim pCmdBar As ICommandBar
    Set pCmdBar = pCmdBars.Find("Project.Parcel Split")
    If Not pCmdBar.IsVisible Then
        pCmdBar.Dock esriDockToggle
    Else
        pCmdBar.Dock esriDockToggle
    End If

End Sub

Thanks

Attachments

Outcomes