writes a character string in a file
mputstr(str [, fd]);
a scalar: a file descriptor returned by the function mopen. -1 stands for last opened file. Default value is -1.
a character string.
The mputstr function allows to write a character string str in a binary file.
this_file = pathconvert(TMPDIR+"/mputstr.txt", %F); fd = mopen(this_file, "wt"); mputstr("Scilab", fd); mclose(fd); mgetl(this_file) // Scilab | ![]() | ![]() |