SilverScreen Solid Modeler



Previous topic Next topic  


Previous topic Next topic JavaScript is required for the print function  



int sprintf( char *buf, char *fmt, ... )


char *buf;        /* character buffer to receive output */

char *fmt;        /* format string */




#include "stdio.h"


The sprintf function writes text to the character array at buf according to format string fmt . Arguments following fmt are formatted and printed in the output string.




buf is the address of a character buffer that is to receive the output string. fmt is a null-terminated string containing format conversion specifications.



Return Value

sprintf returns the length of the string copied into buf .




The types of arguments must match those expected by the format specifiers in fmt , and the number of arguments must be greater than or equal to the number of specifiers in fmt ; otherwise, the result of sprintf is undefined.



See Also

fprintf for a description of format specifiers acceptable to sprintf . printf and ss_command and related functions.