Callout Ballon Change Color
In .Net 2010 VB - I can change the color of the text in my callout balloon, but I can't seem to change the color of the balloon itself. Shadowcolor Doesn't do anything. Any help would be appreciated.
Dim pTextElement As ITextElement = New TextElement
Dim pElement As IElement
Dim pPoint As IPoint = New Point
Dim pCallOut As ICallout = New BalloonCallout
Dim pTextSymbol As IFormattedTextSymbol = New TextSymbol
Dim pGraphicsContainer As IGraphicsContainer = pMxDoc.ActiveView
pPoint = pSelFeat.Shape
pLatLonFormat.IsLatitude = True
pLatLonFormat.GetDMS(pPoint.Y, lDegY, lMinY, lSecY)
pLatLonFormat.IsLatitude = False
pLatLonFormat.GetDMS(pPoint.X, lDegx, lMinx, lSecx)
Dim lngStr As String
Dim latStr As String
lngStr = lDegx & Chr(176) & lMinx & "'" & lSecx & """ " & "W"
latStr = lDegY & Chr(176) & lMinY & "'" & lSecY & """ " & "N"
POI = pSelFeat.Value(pSelFeat.Fields.FindField("POI_NUM"))
WMP = pSelFeat.Value(pSelFeat.Fields.FindField("WMP_TYPE"))
pTextElement.Text = POI & vbCrLf & WMP & vbCrLf & lngStr & vbCrLf & latStr ' add coords"
pTextElement.Symbol.HorizontalAlignment = 0
pTextElement.Symbol.VerticalAlignment = 1
' now reproject so that the placement is in Single Zone
pPoint.Project(pMap.SpatialReference)
' get an offset for the balloon
Dim nPoint As IPoint = New Point
nPoint.SpatialReference = pPoint.SpatialReference
nPoint.X = pPoint.X + 500
nPoint.Y = pPoint.Y + 300
pElement = pTextElement
'pElement.Geometry = pPoint
pElement.Geometry = nPoint
pTextSymbol.Background = pCallOut
pTextSymbol.Size = 8
Dim pColor As ESRI.ArcGIS.Display.IRgbColor = New RgbColor
pColor.Blue = 50
pColor.Green = 240
pColor.Red = 50
'this changes the text color.
pTextSymbol.Color = pColor 'changes the text color OK
'************ this gives me an error ************
'pTextSymbol.Background.TextSymbol.Color = pColor
pCallOut.AnchorPoint = pPoint
pTextElement.Symbol = pTextSymbol
pGraphicsContainer.AddElement(pElement, gcnt)
gcnt = gcnt + 1
pElement.Activate(pMxDoc.ActiveView.ScreenDisplay)
pMxDoc.ActiveView.PartialRefresh(esriViewDrawPhase.esriViewGraphics, Nothing, Nothing)