hi,
i want to develop a windows application using c#.net.The functionality will be like the same as find and replace functionality in windows.
can any body give a full idea how to develope this
thanks a lot in advance.
hi,
i want to develop a windows application using c#.net.The functionality will be like the same as find and replace functionality in windows.
can any body give a full idea how to develope this
thanks a lot in advance.
The Platform SDK / Win32 contains a function FindText that has a common search dialog that you can use.
If you want to search a RichTextBox control in your app, .NET already makes use of FindText in that control via the Find methods.
Hi peter,
Thanks fr reply.
but my tool is like, i ll open a file using that tool.The file may be text file or excel sheet.
In that particular file i want to implement the find and replace functionality.i.e. I ll find a string in that file to replace with another and after that i should able to save the changes in the file.
hope u understand my problem.
can u please give some idea
please reply..............
The following article including good sample and explanation will be very helpful to you.
Find and Replace with Regular Expressions
This article demonstrates how to use regular expressions and RegEx
class (System.Text.RegularExpressions namespace) to build the find and replace functionality found in most of the text editors and word processors. The functionalities like whole word search or case sensitive/insensitive search can be implemented much easier using Regular Expressions than using any other methods.
Another references
Visual Studio Find/Replace Regular Expression usage
Search and Replace text in Notepad RE using Regular Expressions
This response contains a reference to a third party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control these sites and has not tested any software or information found on these sites; therefore, Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. There are inherent dangers in the use of any software found on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet.