int writeString(string str)/file

Writes a string to the file. This method returns a negative value if it fails.