void create_file (Object doc,String fpath)
    {
        Path logfile = FileSystems.getDefault().getPath(fpath);
        //fileW=fpath;
        String s = (String) doc;
        byte data[] = s.getBytes();
        try (OutputStream out = new BufferedOutputStream(
                 Files.newOutputStream(logfile,CREATE))) {
           
            out.write(data, 0, data.length);
            System.out.println("Log file created");
            
        } catch (IOException x) {
            System.err.println(x);
        }
    }