Share via


vprintf, vwprintf (Windows CE 5.0)

Send Feedback

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

Write formatted output using a pointer to a list of arguments.

int vprintf( const char *format, va_listargptr);int vwprintf( const wchar_t *format, va_listargptr);

Parameters

  • format
    Format specification.
  • argptr
    Pointer to list of arguments.

Return Values

vprintf and vwprintf return the number of characters written, not including the terminating null character, or a negative value if an output error occurs.

Remarks

These functions are supported by all versions of the C run-time libraries.

Each of these functions takes a pointer to an argument list, then formats and writes the given data to stdout.

The string to be printed must not be larger than the maximum number of bytes allowed in the buffer; otherwise, a buffer overrun can occur.

This can lead to a denial of service attack against the application if an access violation occurs, or in the worst case, allow an attacker to inject executable code into your process. Consider using an appropriate strsafe function.

For more information, see Safe String Functions.

The following table shows generic-text routine mappings for this function.

TCHAR.H Routine _UNICODE & _MBCS Not Defined _MBCS Defined _UNICODE Defined
_vtprintf vprintf vprintf vwprintf

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

Requirements

OS Versions: Windows CE 2.0 and later.

Header: stdarg.h, stdlib.h, wtypes.h.

Link Library: coredll.dll.

See Also

fprintf | printf | sprintf

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.