Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/357.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/227.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java 用印地语保存信息_Java_Android - Fatal编程技术网

Java 用印地语保存信息

Java 用印地语保存信息,java,android,Java,Android,我正在使用此代码将数据保存到文件中。保存在文件中的数据是?。请帮我找到合适的解决办法 File gpxfile = new File(activate, "activate.csv"); OutputStreamWriter writer = new OutputStreamWriter(new FileOutputStream(gpxfile),"UTF-8"); writer.write(merchantId); 它对我有用。确保merchantId包含有效的Hindi。例如: S

我正在使用此代码将数据保存到文件中。保存在文件中的数据是
。请帮我找到合适的解决办法

File gpxfile = new File(activate, "activate.csv");
OutputStreamWriter writer = new OutputStreamWriter(new FileOutputStream(gpxfile),"UTF-8");
writer.write(merchantId);

它对我有用。确保
merchantId
包含有效的
Hindi
。例如:

    String str = "मानक हिन्दी";
    writer.write(str);

你是否应该知道,你用来读取文件的程序不仅仅是以“?”的形式显示它。尝试使用十六进制编辑器。我猜您的查看器不正确。我认为保存零件没有任何问题