Above given solutions might not work for extensions in upper cases. Enhancing "Penguen"'s solution:
This is my answer of the question posted at stackoverflow.
Regex regx = new Regex(@"([a-zA-Z0_9].*\bxyz)|([a-zA-Z0_9].*\bXYZ)\b");
Replace "xyz" with xlsx and "XYZ" with "XLSX".
Please give me alternate of this expression, if it is a bulky one.This is my answer of the question posted at stackoverflow.
No comments:
Post a Comment