I have a structure like this
struct {
int id;
char str00[10];
char str01[10];
char str03[10];
char str04[10];
...
} myStructure;
All strXX have the same size. I would like to access them via an array (strArray), like this :
strcpy(strArray[i], strValue);
How to declare strArray ?
I used this:
char (*strArray)[][10] = (void *)&myStructure.str00;
It's working, but I have to code the strcpy like this
strcpy((*strArray)[i], strValue);
... and I don't like this :-)
Is there another way to declare strArray ?
Thanks for your ideas and help.