Posted 14 years ago by Paul Huckstepp - United Kingdom
Avatar
Hi,

Could some one help me out with removing an indicator pls.

I have a document open in Syntax Editor 3 that has a squiggly line beneath it which is set:

Dim indicator As SpanIndicator = Nothing
indicator = New SquiggleLineIndicator("ErrorIndicator", 1, Color.Red)
indicator.Tag = "Spelling Error"
Try
   Me.codeWindow2.Document.Indicators.Add(indicator, CInt(previousWord2.startOffset), previousWord2.Length)
Catch
End Try
Now the problem is that I don't know how to do a removal of the same indicator when needed. The Remove function only seems to take an indicator parameter. How can I specify the word/characters to remove the indicator from?

Thanks for your help.

Comments (1)

Posted 14 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
The Document.Indicators collection has a GetSpanIndicatorsForOffset method that returns an array containing the SpanIndicator objects that contain the specified offset. Use that to know what indicators are at an offset.


Actipro Software Support

The latest build of this product (v2018.1 build 0341) was released 9 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.