remove suffix from a wavename

Hi I am trying to make new waves the names of which come from my old wave names. I want to remove the suffix of the old name waves and add on a new suffix because my old wave names are too long and if I only add on another suffix igor would report an error. Since my old wave names are not of equal length or have a pattern, I found it hard to use string indexing with wavename[x,x] to extract the characters. I wonder since strings can be combined by a "+", if there is a way to "-" the characters then? Thank you very much!
A couple of tricks I have used to parse out filenames.

stringV = RemoveEnding(str [, endingStr ]) if you have a fixed suffix you need to remove

I use this a lot when I import images and want to remove the .png or .tif from the file name.

StringV = RemoveEnding(fileNameStr, ".png")

if there is a character that starts the suffix, use can use string from list with that character as delimiter.

StringV = StringFromList(index, listStr [, listSepStr [, offset ]])

such as

StringV = stringfromlist(0, inputstr, "_")

Andy