This project is read-only.

Simple header control v1.7 error....

Nov 22, 2014 at 5:34 PM
I have to admit that programming in dotspatial is survival because i am not a real programmer although i made many programs already....

I upgraded a v1.6 build to v1.7 and an error occured.... in the code below in this command....


if i disable the command the program works but 2 boxes pop up before u can start the program so disabling is not the solution ;o)

Here are the 2 original errors after updating to v1.7 with NuGet:

Error 22 Value of type 'System.Windows.Forms.ToolStripContainer' cannot be converted to 'System.Windows.Forms.ToolStripPanel'. D:\C__VISUAL STUDIO\A_SWING v1.4 07-11-2014 - SIMULATOR - PREDICTOR V1.7\aSWINGviewer\SimpleHeaderControl.vb 50 24 aSWINGviewer

Error 21 Argument not specified for parameter 'menuStrip' of 'Public Sub Initialize(toolStripPanel As System.Windows.Forms.ToolStripPanel, menuStrip As System.Windows.Forms.MenuStrip)'. D:\C__VISUAL STUDIO\A_SWING v1.4 07-11-2014 - SIMULATOR - PREDICTOR V1.7\aSWINGviewer\SimpleHeaderControl.vb 50 13 aSWINGviewer

Anyone have an idea?
Namespace GISProject
    <Export(GetType(IHeaderControl))> _
    Public Class SimpleHeaderControl
        Inherits MenuBarHeaderControl
        Implements IPartImportsSatisfiedNotification

        Private toolStripContainer1 As ToolStripContainer

        <Import("Shell", GetType(ContainerControl))> _
        Private Property Shell() As ContainerControl
                Return m_Shell
            End Get
            Set(ByVal value As ContainerControl)
                m_Shell = value
            End Set
        End Property

        Private m_Shell As ContainerControl

        ''' Called when a part's imports have been satisfied and it is safe to use. (Shell will have a value)
        Public Sub OnImportsSatisfied() Implements IPartImportsSatisfiedNotification.OnImportsSatisfied
            Me.toolStripContainer1 = New ToolStripContainer()

            Me.toolStripContainer1.Dock = DockStyle.Fill
            Me.toolStripContainer1.Name = "toolStripContainer1"

            ' place all of the controls that were on the form originally inside of our content panel.
            While Shell.Controls.Count > 0
                For Each control As Control In Shell.Controls
            End While



        End Sub

    End Class
End Namespace