I have a problem with MessageFormat.format
in my Java backend. I have there a mailing function which sends mails with content from my frontend (passend via api to the backend) to some users.
String text =
MessageFormat.format(
"Dear Report Owner\n\nA new access request:\n\nFrom: {0} {1} ({2})\nFor: {3} \nReason: {4}\n\nPlease process the access request and inform {0} {1} accordingly.\n\nBest regards,\nDev-Team",
accessTokenUser.getGivenName(),
accessTokenUser.getFamilyName(),
accessTokenUser.getEmail(),
processedRoleContent,
processedLinkContent);
It's possible, that some values (e.g. processedRoleContent
) contains for example ü
but in the sent email it appears as Ü
.
How can I configure the MessageFormat.format
that it send's umlauts?
Thank you in advance!