-
Sep 27th, 2004, 03:29 PM
#1
Thread Starter
Lively Member
Return Byte Array Through Function!?!?!
byte val2[10];
BYTE __stdcall getVal2[]()
{
return val2;
}
Won't let me do this...anybody know an alternative?
-
Sep 27th, 2004, 04:23 PM
#2
Frenzied Member
byte is a pointer to the first index of val2, not a byte.
byte* val2[10];
BYTE* __stdcall getVal2[]()
{
return val2;
}
-
Sep 28th, 2004, 05:53 AM
#3
That's simply invalid:
getVal2[]()
What do you want to do?
All the buzzt
CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Sep 28th, 2004, 03:41 PM
#4
Looks like he just wants to return a BYTE* from a function.
I think this is what you want?
Code:
BYTE val2[10];
BYTE* __stdcall getVal2()
{
return val2;
}
why not just reference val2 directly?
Every passing hour brings the Solar System forty-three thousand miles closer to Globular Cluster M13 in Hercules -- and still there are some misfits who insist that there is no such thing as progress.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|