Menu

#1 File Not Found Exception not doing {0} replace

open
nobody
None
5
2006-12-07
2006-12-07
No

I had an incorrect filename in my sign task call. It failed with the message that the file could not be found, but rather than the name of the file, the replacement variable {0} was still there. I noticed in the source that the name is being surrounded by single quotes. Single quotes for the MessageFormat class are quote characters. I think you need ''{0}'' to get the effect I believe you are shooting for. Using '{0}' starts a quote and no longer treats the {0} as a replacement slot.

Discussion


Log in to post a comment.

MongoDB Logo MongoDB