Share via


puts, _putws (Windows CE 5.0)

Send Feedback

Developing an Application > Microsoft C Run-time Library for Windows CE > Run-time Library Reference

Write a string to stdout.

int puts(    const char*string);int _putws(    const wchar_t*string);

Parameters

  • string
    Output string.

Return Values

Each returns a nonnegative value if successful.

If puts fails it returns EOF.

If _putws fails it returns WEOF.

Remarks

The puts function writes string to the standard output stream stdout, replacing the string's terminating null character ('\0') with a newline character ('\n') in the output stream.

Generic-Text Routine Mappings

TCHAR.H Routine _UNICODE Defined
_putts _putws

For more information about TCHAR.H routines, see Generic Text Mappings.

Example

/* PUTS.C: This program uses puts
 * to write a string to stdout.
 */

#include <stdio.h>

void main( void )
{
   puts( "Hello world from puts!" );
}

Output

Hello world from puts!

Requirements

OS Versions: Windows CE 2.0 and later.
Header: stdlib.h.
Link Library: coredll.dll.

See Also

gets

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.