Very new to this, so please excuse any ignorant question! I've created a vb.net app to open a published map in ArcReader. Have a few questions...
First, I started with the query attribute sample to find an address, zoom to the point on the map, and flash. I'd like to have a balloon callout display showing the address on the map as well.
From this site, I tried the following code (below), but trying to use ICallout and IFormattedText Symbol tells me 'ambiguously defined for esri.ArcGIS.Display'.
I'm using ArcReaderControl to build this and then adding on to it. Have I missed something simple?
Thank you very much for any help you have!
DonnaB
Private Sub AddBalloonCallout(ByVal activeView As IActiveView, ByVal text As String, ByVal x As Double, ByVal y As Double)
Dim pTextElement As ITextElement
Dim pElement As IElement
Dim pPoint As IPoint
Dim pCallout As ICallout
Dim pTextSymbol As IFormattedTextSymbol
Dim pGraphicsContainer As IGraphicsContainer
Dim midX As Double, midY As Double
Dim pCallout As ICallout
pTextSymbol = New ESRI.ArcGIS.Display.TextSymbol
'Dim pTextSymbol As IFormattedTextSymbol
Dim pGraphicsContainer As IGraphicsContainer
Dim midX As Double, midY As Double
'Create a new text element
pTextElement = New TextElement
pElement = CType(pTextElement, IElement) 'QI
pTextElement.Text = "Text callout" & vbCrLf & text
'Position the new element on the active view's center point
midX = (activeView.Extent.XMax + activeView.Extent.XMin) / 2
midY = (activeView.Extent.YMax + activeView.Extent.YMin) / 2
pPoint = New ESRI.ArcGIS.Geometry.Point
pPoint.PutCoords(midX, midY)
pElement.Geometry = pPoint
'Set the text element symbology to a default balloon callout
pTextSymbol = New ESRI.ArcGIS.Display.TextSymbol
pCallout = New BalloonCallout
pTextSymbol.Background = CType(pCallout, ITextBackground)
End Sub
