Click to See Complete Forum and Search --> : Pointer to an Array of Objects
IrishJoker
Aug 20th, 2002, 03:10 AM
Hi,
I need to know how to create a Pointer to an array of object handles...
I need this to use the WaitForMultipleObjects API function.
Does anyone have a sample of code to show how to use it
Regards
IJ...
abdul
Aug 20th, 2002, 03:43 AM
Won't something this work?
int *mypointer = myarray;
IrishJoker
Aug 20th, 2002, 03:48 AM
How do I add Handles to that array.
I am Creating Threads and I get a Handle to them, now what I need is to have them in an array.
I also need to know how to get the amount of HANDLES in the array. Would sizeof do the trick...??
Regards
IJ...
abdul
Aug 20th, 2002, 04:04 AM
How are you declaring the array? You want to declare an array of pointers of a pointer to an array? I think WaitForMultipleObjects returns a handle that you can simply pass to *mypointer (not mypointer). If you want to point to next item in the array (if you're using a pointer to an array), you can increase the pointer like this:
mypointer++;
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.