Use
string[] tokens = originalFileName.Split(new char[] {'-', '.'});
After that, re-compose the output string fragment at your liking. Prefer
string.Format
over string concatenation, for example:
int tokenLength = tokens.Length;
if (tokenLength > 2)
myNewFileName = string.Format("{0}-{1}.{2}",
tokens[0], tokens[1], tokens[tokenLength - 1]);
—SA