[ScintillaNET] Re: Find Replace

  • From: mike.griffin@xxxxxxxxxxxxxxxxxxxxxxxx
  • To: scintillanet@xxxxxxxxxxxxx
  • Date: Fri, 6 Aug 2004 13:12:48 -0700 (PDT)

Yea, but there's a user out their (I lost the email) that has the full
dialog and everything working really nice, maybe Garrett has it?


> find and replace is fairly simple to implement. this is what i've been
> using for awhile... its not perfect, but it gets the job done.
>
> |            if(d.Direction == FindDialog.SearchDirection.Up)
>             {
>
> if(scintilla.SelText.Substring(0,scintilla.SelTextSize-1)==s)
>                 {
>                     scintilla.CurrentPos = scintilla.SelectionStart-1;
>
>                     scintilla.SelectionStart=scintilla.CurrentPos;
>                     scintilla.SelectionEnd = scintilla.CurrentPos;
>                 }
>
>                 scintilla.SearchAnchor();
>                 pos = scintilla.SearchPrev(flags, s);
>             }
>             else
>             {//:)
>
> if(scintilla.SelText.Substring(0,scintilla.SelTextSize-1)==s)
>                 {
>                         scintilla.CurrentPos = scintilla.SelectionEnd;
>                     scintilla.SelectionStart = scintilla.CurrentPos;
>                       scintilla.SelectionEnd = scintilla.CurrentPos;
>                 }
>
>                                     scintilla.SearchAnchor();
>                                 pos=scintilla.SearchNext(flags, s);
>             }
>
>             if(pos>-1)
>             {
>
>                 scintilla.GotoPos(pos);
>
>                 scintilla.SelectionStart=pos;
>                 scintilla.SelectionEnd=pos + s.Length;
>
>             }|
>
> Regards,
> /*Greg Dietsche*/**     http://www.gregd.org/ <http://www.gregd.org>
> *GForce Programming:*   http://calc.gregd.org
> *Detached Solutions:*      http://www.detachedsolutions.com
>
> **
>
>
>
> mike.griffin@xxxxxxxxxxxxxxxxxxxxxxxx wrote:
>
>>My users are going to string me up, help !!  They are demanding find and
>>replace, do we have the logic for this?  Garrett, is there anyway I can
>>help?
>>
>>--------------------------------------------------------------------------
>>ScintillaNET Mailing List: ScintillaNET@xxxxxxxxxxxxx
>>
>>    To unsubscribe: Send an email to scintillanet-request@xxxxxxxxxxxxx
>>    and put "unsubscribe" (without the quotes) in the Subject line.
>>
>>    Web Page: http://tinyurl.com/yvoh2
>>
>>
>>
>>
>>
>
> --
>
> Regards,
> /*Greg Dietsche*/**     http://www.gregd.org/ <http://www.gregd.org>
> *GForce Programming:*   http://calc.gregd.org
> *Detached Solutions:*      http://www.detachedsolutions.com
>
> **
>
>


--------------------------------------------------------------------------
ScintillaNET Mailing List: ScintillaNET@xxxxxxxxxxxxx

    To unsubscribe: Send an email to scintillanet-request@xxxxxxxxxxxxx
    and put "unsubscribe" (without the quotes) in the Subject line. 

    Web Page: http://tinyurl.com/yvoh2

Other related posts: