How do I change the microedi开发者_StackOverflow中文版tion.encoding
for a BlackBerry application?
I can only view it with System.getProperty("microedition.encoding")
. I have tried to send it as an argument from the application descriptor microedition.encoding="UTF-8"
, but it has no effect.
As Arhimed said, your question is not so clear. It would be better if you can brief us on your problem. However if you are looking for some URL encoding you can also try this. Method:
private String encodeString(String hsURL)
{
URLEncodedPostData
urlEncoder = new URLEncodedPostData("UTF-8", false);
urlEncoder.append("url", hsURL);
hsURL = urlEncoder.toString();
hsURL = hsURL.substring(4);
return hsURL;
}
精彩评论