Managed Debugging Assistant 'DisconnectedContext' has detected a problem

Hi!

So I was trying to build a costum component (vb) for grasshopper in Visual Studio and started to have this DisconnectedContext problem “Managed Debugging Assistant ‘DisconnectedContext’ has detected a problem in ‘C:\Program Files (x86)\Rhinoceros 5.0\System\Rhino4.exe’” while debbuging.

Following this error i created two different projects.

In the first project the input consists of a list of points and the output the number off nodes in the list

Protected Overrides Sub RegisterInputParams(pManager As GH_Component.GH_InputParamManager)
        pManager.AddPointParameter("Points", "Points", "Points to input", GH_ParamAccess.list)
    End Sub

Protected Overrides Sub RegisterOutputParams(pManager As GH_Component.GH_OutputParamManager)
        pManager.AddNumberParameter("Number", "N", "Number of nodes", GH_ParamAccess.item)
    End Sub

Protected Overrides Sub SolveInstance(DA As IGH_DataAccess)

        Dim list_p As New List(Of Point3d)
        Dim p As Point3d = Point3d.Unset
        Dim l As Integer

        If (Not DA.GetDataList(0, list_p)) Then Return

        l = list_p.Count

        DA.SetData(0, l)

    End Sub

*The second project the input consists of a list of lines and the output the number off lines in the list*

Protected Overrides Sub RegisterInputParams(pManager As GH_Component.GH_InputParamManager)
        pManager.AddLineParameter("Lines", "Lines", "Lines to input", GH_ParamAccess.list)
    End Sub

Protected Overrides Sub RegisterOutputParams(pManager As GH_Component.GH_OutputParamManager)
        pManager.AddNumberParameter("Number", "N", "Number of lines", GH_ParamAccess.item)
    End Sub

Protected Overrides Sub SolveInstance(DA As IGH_DataAccess)

        Dim list_ln As New List(Of Line)
        Dim ln As Line = Line.Unset
        Dim l As Integer

        If (Not DA.GetDataList(0, list_ln)) Then Return

        l = list_ln.Count

        DA.SetData(0, l)

    End Sub

In both of them when I start to debbug, Rhino launches with no problem but inside Rhino, when I call grasshopper the ‘DisconnectedContext’ exception occurs. This exception doesn’t occur consistently everytime I start the debbug in both the projects mentioned above. I’ve read that I can simply uncheck the DisconnectedContext in the Exception Settings but I would like to understand what’s happening here, if someone could help

Thanks