Hi everyone
I have an operation in my programm where i have to copy parts of a pointer pointing to an array of chars into another char at another pointers address.
Declaration:
The function:Code:struct EXIF { char DateTimeOriginal[20]; char Year[4]; char Month[2]; char Day[2]; char Hour[2]; char Minute[2]; char Second[2]; ... };
However this just copies the whole string into the other array but i just want the first 4 characters of pEXIF->DateTimeOriginal stored into pEXIF->Year.Code:for (int a = 0; a <= 3; a++) { pEXIF->Year[a] = pEXIF->DateTimeOriginal[a]; ... }
I'm not that firm in pointer stuff so I hope one of you has a tip for me
greetings
ghost



LinkBack URL
About LinkBacks




