In a C# 2008 desktop application, I want to obtain data that is part of the file name. I want to obtain the following:
1. Data that is the first character to where the first '_' is located,
2. data from the first '_' to the second '_'.
Thus can you tell me how to code the above using C#.net 2008?
Loading
VulpesPosted Dec 19, 2012, 10:07 AM
string[] items = fileName.Split('_');
items[0] will be the portion to the first _ and then items[1] will be the portion from the first _ to the second _.
These will exclude the underscores themselves.
VulpesPosted Dec 19, 2012, 10:39 AM