Replace Multiple Substrings in a String at Once

Category:
String Manipulation
Type:
Snippets
Difficulty:
Beginning
Author:
Intelligent Solutions Inc.

Version Compatibility: Visual Basic 6

More information:
Often, you may one to replace multiple substrings in a string with the same character. For instance, you may have a list of unwanted characters that you always want to replace with an empty string. By using this function, you can perform this task without repeatedly having to call Replace. See comments in code for usage and example.

Instructions: Copy the declarations and code below and paste directly into your VB project.

Declarations:

Code: