Home News DOC Class DL Others Rice
Class  >  writer  >  writer(string,bool,string)
writer class : writer(string,bool,string) fitter


Gets a new instance of writer class which is initialized with the file path, writing mode, and encoding.


new writer(string fullPath, bool append, string encodingName)


stringfullPathThe complete file path.
boolappendThe value that indicates the writing mode.
stringencodingNameThe encoding name.

Return value

writerA new instance of writer class that is initialized by specified value.

Sample code


writer w = new writer("c:\somewhere...\sample.txt", true, "shift_jis");


It's a wrapper of the System.IO.StreamWriter.StreamWriter(String,Boolean,Encoding) constructor.

If sets the true to the second argument, the instance of writer type is initialized as append mode. Otherwise, it is initialized as overwrite mode.

Creates an instance of the writer class with the encoding specified by the third argument. Encoding will be specified by the encoding name.

Links for reference

Copyright © Rice All rights reserved.