Mark:
Here are 3 approaches, confined to standard worksheet fuctions.
Note: For the sake of clarity I have used CHAR(44) for "," (a comma in
quotes) and CHAR(32) for " " (a space within quotes) in all examples. They
are equivalent, just less confusing than a lot of quote marks and commas.
You might want to use "" (an empty string) in place of CHAR(32). I've
momentarily forgotten whether there is a CHAR() code for an empty string but
I don't think there is. I dare say someone will correct me if I'm wrong
Also: In the first 2 examples, if leading or trailing spaces might be an
issue, use TRIM(A1) rather than A1.
If the last character in the string is a comma, this will return that string
without the last character, otherwise it returns an unchanged string:
=IF(RIGHT(A1, 1) = CHAR(44), LEFT(A1, LEN(A1) -1), A1)
If the last character in the string is a comma, this will change that
character to a space, otherwise it returns an unchanged string:
=IF(RIGHT(A1, 1) = CHAR(44), REPLACE(A1, LEN(A1), 1, CHAR(32)), A1)
This will change the 2nd occurance of a comma within a string (if there is
one) to a space, otherwise it returns an unchanged string:
=SUBSTITUTE(A1, CHAR(44), CHAR(32), 2)
Note: this assumes that the offending end-of-line comma, if it occurs, will
*always* be the 2nd occurance and *only* the 2nd occurance (not the 1st, not
the 3rd).
This would be my last choice for that reason.
Hope this helps,