Original Post
Hi friends, Two basic questions: 1) How to execute a command line from the code (C/C++)? For example, I would like to execute a command line like this: "lame --alt-preset standard - song.mp3" 2) Please, look the following codes: ------------------------------------------
CODE 1:
LPSTR MyString(LPSTR buffer)
{
_itoa(timeGetTime(), buffer, 10 );
return buffer;
}
char buffer[20] = "";
printf("%s", MyString(buffer));
------------------------------------------
CODE 2:
LPSTR MyString()
{
char buffer[20] = "";
_itoa(timeGetTime(), buffer, 10 );
return buffer;
}
printf("%s", MyString());
------------------------------------------ CODE 1 works, but CODE 2 doesn't work... Why? Thanks in advance