Description |
I wrote this for a company that was importing a variety of rich text separated by tabs. By applying this regular expression, you can filter out even empty fields which return as a single tab qualified by a tab in front of them unless its the end of the string, which will return a single tab as well. You can filter out the returned tabs in your .NET code.
For NEWBIES, this expression says:
"Return anything but Tabs, and separate data by the tabs" [^\t]+
"Or" |
"For Empty Tabs, Return those that have a tab in front of them" \t(?=\t)
"Or" |
"Return Empty Tabs at the end of a string"
\t$
Hope this helps you on your journey in learning Regular Expressions! You can contact me using my form at http://www.thomasdcox.com/contactme.aspx |