This is not specific to Visual C++'s compiler, either. This is a language-level thing (when you think about it, it should be pretty obvious why this doesn't work).
A cursory search of the MSDN reveals no "CreateButton" function. However, even if one existed, its not really pertinant to the problem. A functions name and the types of its parameters are considered in overload resolution in C++, so unless his CreateButton function matched this mythical Win32 CreateButton function exactly in terms of parameter types, the compiler would be able to disambiguate the overload (at least between the "Win32" CreateButton and one of the OP's CreateButton functions).
Quote:
char *ParseData(char *cData, int start, int end);
void ParseData(char *cData, int start, int end,char **retr);
I understand what your trying to get at (overload selection is based on function name and parameter types, but not return type), but this example is not particularly clear because you've completely changed the function name and types and provided very little context or information about what exactly is going on.
To the OP: If you have two button creation functions that perform very different actions (it appears that you have one to create a button with a hilight texture, and one to create a button with a "clicked" texture -- why you need two separate functions for this isn't clear to me, but I digress) but require the same parameter types, you cannot rely on overloads to accomplish this -- you've got to name your functions two different things.
[Edited by - jpetrie on May 16, 2006 9:19:08 PM]