|
-
Aug 21st, 2009, 03:09 AM
#17
Re: Extracting an image from an external application
IntPtr is used to store handles and pointers in VB. Any API function that returns a handle or a pointer can be declared in VB to return either an Integer or an IntPtr. Either will work fine. If you then want to call a method that takes an IntPtr as an argument it would make sense for you to declare your API function to return an IntPtr.
That said, it's easy to convert between Integer and IntPtr. The IntPtr structure has a constructor that takes an Integer as an argument and it also has a ToInt32 method that returns an Integer, so you can go either way.
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
|