Here you can find the source of writeStringToFile(String macroContent, File file)
public static void writeStringToFile(String macroContent, File file)
//package com.java2s; //License from project: Open Source License import java.io.File; public class Main { public static void writeStringToFile(String macroContent, File file) { try {/*from ww w .ja v a 2s.c o m*/ java.io.FileWriter w = new java.io.FileWriter(file); w.write(macroContent); w.close(); } catch (Exception e) { } } }