Hỏi về đổi tên thư mục sang lại tiếng Anh

E vừa cài lại win và tên thư mục của e đang ở tiếng Việt, khi cài file nó báo lỗi không nên có chữ tiếng Việt trong tên folder, e không biết làm sao để đổi lại tên thư mục đấy, mn ai biết chỉ e với

{3BE4CB53-5746-4CFC-9269-39854A7201B4}

If you are a developer you can write a small app to do this. For example, in JAVA

import java.io.*;
// @author Joe T. Schwarz (c)
public class Rename {
  public static void main(String... argv) throws Exception {
    if (argv.length != 2) {
      System.out.println("Usage: java Rename oldName newName");
      System.exit(0);
    }
    (new File(argv[0])).renameTo(new File(argv[1]));
  }
}

To rename a file or directory to English, compile and run it as follows:

joe@Schwarz:~/joeapp/NanoDB/examples$ javac -g:none  Rename.java
joe@Schwarz:~/joeapp/NanoDB/examples$ java -DFile.encoding=UTF-8 Rename vừa_cài.txt newCai.txt
joe@Schwarz:~/joeapp/NanoDB/examples$

As you see I have renamed the file vừa_cài.txt in Vietnamese to newCai.txt in English. :grinning:

Tui thấy mấy ông định học lập trình mà cài Windows tiếng Việt là tui chỉ có thể nói “quay đầu là bờ”.

2 Likes
83% thành viên diễn đàn không hỏi bài tập, còn bạn thì sao?