|
-
Feb 7th, 2010, 02:22 PM
#1
Thread Starter
Frenzied Member
[RESOLVED] Set return type of function based on internal variable type
Hi guys!
Another question for you. Hopefully someone knows the answer to this one and is willing to point me in the right direction.
What I have is a function that reads a WMI Query then returns a specific property that is specified in the argument for the function.
What I'd like to do is make the function return the property in it's original type. I don't want to use object because I'd still have to cast it later.
So basically I need a way to make a functions return type the same as the type of the variable. I'm not sure if this can be done with generics or not since I've never used them so pointers would be appreciated.
Thanks everyone!
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
|