VBcoders Browse New Submit Contact Sign In

No account? Register free

Forgot password?

Search a String and Highlight (SrchString)

silverx10  (5 Submissions)   Miscellaneous   Visual Basic 3.0   Beginner   Wed 3rd February 2021

This source code will search for a certain string from a TextBox (can be modified to search from any string-bearing control, etc.). Once the string is found, a message box will appear letting you know that the string was found, and then the string will be highlighted.

Assumes
1) Start a new Standard EXE project. 2) Add two (2) TextBox controls to the Form. 3) Erase the contents of the TextBox controls. Alternately, you can set Text2's Multiline property to True, as it is going to be the TextBox to search for the string in. 4) Add one (1) CommandButton control to the Form. 5) Set the CommandButton Caption property to "&Search" 6) Click the View Code button; copy and paste the source code below. 7) Run the application. 8) Visit my website! http://www.matnet.com/~pyrosoft

Rate Search a String and Highlight (SrchString) (3(3 Vote))
Search a String and Highlight (SrchString).bas

Search a String and Highlight (SrchString) Comments

No comments yet — be the first to post one!

Post a Comment

0/1000 characters