HtmlEditor :  Phorum 5 The fastest message board... ever.

This is the discussion forum for the HtmlEditor. See also the HtmlEditor home page, where you can download the control, and the Documentation Wiki, a collaborative project for documenting the control.

Goto Thread: PreviousNext
Goto: Forum ListMessage ListNew TopicSearchLog In
Any Suggestions for Find/Replace
Posted by: James Hancock (---.darwinconsulting.com)
Date: Tuesday, 31-Dec-2002, 18:23:47

Anyone have any suggestions on how I would go about implimenting Find and Replace functionality?

I know I can do it the brute force way, but I would rather if there was an easy way.

Thanks!
James Hancock

Re: Any Suggestions for Find/Replace
Posted by: Kushan Ratnayake (203.115.18.---)
Date: Thursday, 16-Jan-2003, 03:54:04

Use IMarkupServices and IMarkupPointers to implement it.

Re: Any Suggestions for Find/Replace
Posted by: Kushan Ratnayake (203.115.18.---)
Date: Thursday, 16-Jan-2003, 04:08:20

Following code shows how you can create and position markup pointers to HTMLDocument (docCtl) body. (in VB.NET)

Dim x As mshtml.IMarkupServices = docCtl
Dim bodyrg As mshtml.IHTMLTxtRange = CType(docCtl.body, mshtml.IHTMLBodyElement).createTextRange()

Dim ps, pe As mshtml.IMarkupPointer

x.CreateMarkupPointer(ps)
x.CreateMarkupPointer(pe)
x.MovePointersToRange(bodyrg, ps, pe)

Refer MSDN article on Introduction to MarkupServices.


Kushan Ratnayake



Your Name: 
Your Email: 
Subject: 
Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically.
4NuwY
This is a moderated forum. Your message will remain hidden until it has been approved by a moderator or administrator
This forum powered by Phorum.