# mputstr

writes a character string in a file

## Calling Sequence

    mputstr(str [, fd]);

## Arguments

fd

  a scalar: a file descriptor returned by the function `mopen`. `-1` stands for last opened file. Default value is `-1`.

str

  a character string.

## Description

The `mputstr` function allows to write a character string `str` in a binary file.

## Examples

    this_file = pathconvert(TMPDIR+"/mputstr.txt", %F);

    fd = mopen(this_file, "wt");
    mputstr("Scilab", fd);
    mclose(fd);

    mgetl(this_file) // Scilab

## See Also

- mclose
- meof
- mfprintf
- fprintfMat
- mfscanf
- fscanfMat
- mget
- mgetstr
- mopen
- mprintf
- mput
- mseek
- mtell
- mdelete