Dear Yale
As per Sample made in C Sharp for Map suite explorer, I have created ThemeItem and ThemeView Control in vb.net. I think there is something missing in code, so the event on check box change and selection of theme item not fire. Pleas help.
Private Sub SetupThemeItem(ByVal layer As Layer)Dim themeItem As New ThemeItem()
themeItem.ShapeName = layer.Name
AddHandler themeItem.ItemCheckedChanged, AddressOf themeItem_ItemCheckedChanged
AddHandler themeItem.ItemLinkClicked, AddressOf themeItem_ItemLinkClicked
AddHandler themeItem.ThemeItemClick, AddressOf themeItem_ThemeItemClick
AddHandler themeItem.ThemeItemRightClick, AddressOf themeItem_ThemeItemRightClickEnd Sub
Private Sub themeItem_ItemCheckedChanged(ByVal sender As Object, ByVal e As ShapeEventArgs)If DirectCast(winformsMap1.Overlays(0), LayerOverlay).Layers.Contains(e.ShapeName) Then
winformsMap1.Overlays(0).Lock.EnterWriteLock()
Try
DirectCast(winformsMap1.Overlays(0), LayerOverlay).Layers(e.ShapeName).IsVisible = e.IsShow
Finally
winformsMap1.Overlays(0).Lock.ExitWriteLock()
End Try
Try
DrawImage()
Catch
End Try
End If
End Sub
But the ThemeItem_ItemCheckedChanged Event not fire. Or Please can you provide Map Suite Explorer Sample copy in Vb.net
Regrards
Sanjay
ThemeView.Items.Add(layer.Name, themeItem)
End Sub