' add the Layer to the Chart Layer Hashtable UltraChart1.Layer.Add("My Layer", New MyLayer) ' update the UserLayerIndex with the new Layer ID UltraChart1.UserLayerIndex = New String() {"Default", "My Layer"} ' it is important to invoke InvalidateLayers so that the chart will redraw all layers UltraChart1.InvalidateLayers()
// add the Layer to the Chart Layer Hashtable UltraChart1.Layer.Add("My Layer", New MyLayer) // update the UserLayerIndex with the new Layer ID UltraChart1.UserLayerIndex = New String() {"Default", "My Layer"} // it is important to invoke InvalidateLayers so that the chart will redraw all layers UltraChart1.InvalidateLayers()