What is the reason? Here the code on which the compiler swears.
char ** funcParam = { "eventId", "eventName" };
What is the reason? Here the code on which the compiler swears.
char ** funcParam = { "eventId", "eventName" };
Because char ** is a single pointer to a pointer, and what do you submit to the input?
Need to
char * funcParam[] = { "eventId", "eventName" };
UPD: {"eventId", "eventName"} is an array of pointers, i.e. as if char * value [], i.e. many addresses, and char ** is just one pointer, one address in memory. Therefore, the message is.
Most likely, this is not the only compiler error, he gave me another
error C2440: 'initializing' : cannot convert from 'const char [8]' to 'char **'
What does it mean that the compiler cannot convert char [8], i.e. "eventId" to pointer to char.
Rewrite the code, it works like this:
char *funcParam[] = { "eventId", "eventName" };
Source: https://ru.stackoverflow.com/questions/2312/
All Articles