I am not a coder or an expert to ask a good question about C# , I am just presenting how I understand on how to split this string IMG10001 to became separate string or field on C # code.
field1 = IMG1
field2 = 0001
Ah! That makes a bit more sense. There are a large number of ways to do it, depending on the data you are dealing with. If it is fixed length - always 3 alphabetic followed by a bunch of numeris, then use the String.Substring method:
string inp = "IMG0001";
string prefix = inp.Substring(0, 3);
string suffix = inp.Substring(3);
Alternatively, if the data can vary in length, then a simple Regex would do it:
Regex reg = new Regex(@"(?<prefix>[A-Za-z]+)(?<suffix>\d+)");
Match m = reg.Match(inp);
if (m.Success)
{
prefix = m.Groups["Prefix"].Value;
suffix = m.Groups["Suffix"].Value;
}</suffix></prefix>