G
greyham
Hi. I'm a beginner to C++ so bear with me. I'm trying to pass a
character array to a new thread so I thought I could pass the pointer
to the character array and cast it as a LPVOID (I know nothing about
LPVOIDs by the way). So I currently have:
AfxBeginThread(myThread,(LPVOID) *myBuffer);
My method myThread looks like:
UINT myThread(LPVOID LParam) {
....
character array to a new thread so I thought I could pass the pointer
to the character array and cast it as a LPVOID (I know nothing about
LPVOIDs by the way). So I currently have:
AfxBeginThread(myThread,(LPVOID) *myBuffer);
My method myThread looks like:
UINT myThread(LPVOID LParam) {
....
Code:
...
char* sendBuffer = (char*)LParam;
....[code]...
}
But sendBuffer doesn't point to myBuffer. Any suggestions? Sorry I
can't describe the problem better - I hope you know what I want to do.
But thanks for the help!