Click here to Skip to main content
15,913,773 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Error : 'strcpy_s' : none of the 2 overloads could convert all the argument types. Pin
Hans Dietrich15-Apr-11 20:52
mentorHans Dietrich15-Apr-11 20:52 
AnswerRe: Error : 'strcpy_s' : none of the 2 overloads could convert all the argument types. Pin
«_Superman_»15-Apr-11 21:09
professional«_Superman_»15-Apr-11 21:09 
GeneralRe: Error : 'strcpy_s' : none of the 2 overloads could convert all the argument types. Pin
Le@rner15-Apr-11 21:37
Le@rner15-Apr-11 21:37 
GeneralRe: Error : 'strcpy_s' : none of the 2 overloads could convert all the argument types. Pin
«_Superman_»15-Apr-11 21:46
professional«_Superman_»15-Apr-11 21:46 
AnswerRe: Error : 'strcpy_s' : none of the 2 overloads could convert all the argument types. Pin
David Crow16-Apr-11 3:59
David Crow16-Apr-11 3:59 
AnswerRe: Error : 'strcpy_s' : none of the 2 overloads could convert all the argument types. Pin
linc_lee16-Apr-11 4:15
linc_lee16-Apr-11 4:15 
GeneralRe: Error : 'strcpy_s' : none of the 2 overloads could convert all the argument types. Pin
David Crow16-Apr-11 10:32
David Crow16-Apr-11 10:32 
AnswerRe: Error : 'strcpy_s' : none of the 2 overloads could convert all the argument types. Pin
refla17-Apr-11 1:41
refla17-Apr-11 1:41 
#include <stdlib.h>
#include <stdio.h>

void main( void )
{
int i;
char *pmbnull = NULL;
char *pmbhello = (char *)malloc( MB_CUR_MAX );
wchar_t *pwchello = L"Hi";
wchar_t *pwc = (wchar_t *)malloc( sizeof( wchar_t ));

printf( "Convert to multibyte string:\n" );
i = wcstombs( pmbhello, pwchello, MB_CUR_MAX ); // Look here !
printf( "\tCharacters converted: %u\n", i );
printf( "\tHex value of first" );
printf( " multibyte character: %#.4x\n\n", pmbhello );

printf( "Convert back to wide-character string:\n" );
i = mbstowcs( pwc, pmbhello, MB_CUR_MAX ); // And here !
printf( "\tCharacters converted: %u\n", i );
printf( "\tHex value of first" );
printf( " wide character: %#.4x\n\n", pwc );
}

Best wish!
QuestionVisual Studio 4.1 Pin
venkat11615-Apr-11 19:15
venkat11615-Apr-11 19:15 
AnswerRe: Visual Studio 4.1 Pin
«_Superman_»15-Apr-11 21:17
professional«_Superman_»15-Apr-11 21:17 
QuestionAlgorithm [modified] Pin
Cyclone_S15-Apr-11 13:40
Cyclone_S15-Apr-11 13:40 
AnswerRe: Algorithm Pin
Hans Dietrich15-Apr-11 18:07
mentorHans Dietrich15-Apr-11 18:07 
QuestionVC, Linker Tools Warning LNK4086 Pin
refla15-Apr-11 13:22
refla15-Apr-11 13:22 
AnswerRe: VC, Linker Tools Warning LNK4086 Pin
Hans Dietrich15-Apr-11 18:55
mentorHans Dietrich15-Apr-11 18:55 
GeneralRe: VC, Linker Tools Warning LNK4086 Pin
refla17-Apr-11 1:31
refla17-Apr-11 1:31 
AnswerRe: VC, Linker Tools Warning LNK4086 Pin
Hans Dietrich17-Apr-11 1:35
mentorHans Dietrich17-Apr-11 1:35 
GeneralRe: VC, Linker Tools Warning LNK4086 Pin
refla17-Apr-11 2:09
refla17-Apr-11 2:09 
AnswerRe: VC, Linker Tools Warning LNK4086 Pin
Hans Dietrich17-Apr-11 2:30
mentorHans Dietrich17-Apr-11 2:30 
GeneralRe: VC, Linker Tools Warning LNK4086 Pin
refla18-Apr-11 10:44
refla18-Apr-11 10:44 
QuestionBuild Error - Creating a DirectSound secondary buffer [modified] Pin
Paul Hasler15-Apr-11 4:44
Paul Hasler15-Apr-11 4:44 
AnswerRe: Build Error - Creating a DirectSound secondary buffer Pin
Richard MacCutchan15-Apr-11 5:06
mveRichard MacCutchan15-Apr-11 5:06 
GeneralRe: Build Error - Creating a DirectSound secondary buffer Pin
Paul Hasler15-Apr-11 5:19
Paul Hasler15-Apr-11 5:19 
GeneralRe: Build Error - Creating a DirectSound secondary buffer Pin
Richard MacCutchan15-Apr-11 6:01
mveRichard MacCutchan15-Apr-11 6:01 
GeneralRe: Build Error - Creating a DirectSound secondary buffer Pin
Paul Hasler15-Apr-11 6:48
Paul Hasler15-Apr-11 6:48 
GeneralRe: Build Error - Creating a DirectSound secondary buffer Pin
Richard MacCutchan15-Apr-11 7:26
mveRichard MacCutchan15-Apr-11 7:26 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.