Click here to Skip to main content
15,911,039 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi I just want to learn Platform Invoke in c#, but I found the parameters for every platform I try to invoke is different, how can I learn what are the parameters for a API I try to invoke and use in my code? Just memorizing all of them (Almost impossible) or I need to start in other way?
Thanks
Posted
Comments
sjelen 13-Mar-12 10:38am    
A good place to start is http://pinvoke.net/
mehdi_k 13-Mar-12 12:09pm    
nice website, Thanks.
Tim Groven 13-Mar-12 11:03am    
Agree with sjelen. That website is invaluable.
El_Codero 13-Mar-12 11:40am    
Also agree with you. Vote for pinvoke.

Start with this tutorial[^].
 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 13-Mar-12 22:23pm    
Good one, my 5.

I advise three different sources, please see my answer (where I also credit yours).
--SA
Rubaba 14-Mar-12 18:06pm    
5++
Something more in addition to the advice by Richard:

Interestingly, just the Wikipedia article on the topic is not just a good overview, but also a good introductory manual:
http://en.wikipedia.org/wiki/Platform_Invocation_Services[^].

See also:
http://msdn.microsoft.com/en-us/library/Aa712982[^].

Finally, this CodeProject article can be quite useful:
Essential P/Invoke[^].

—SA
 
Share this answer
 
Comments
Richard MacCutchan 14-Mar-12 5:26am    
Returning the compliment. Yes, there are lots of resources available for most subjects, if one takes the trouble to look.
Sergey Alexandrovich Kryukov 14-Mar-12 11:55am    
Thank you, Richard.
--SA
Rubaba 14-Mar-12 18:06pm    
5++
Sergey Alexandrovich Kryukov 14-Mar-12 19:18pm    
Thank you, Rubaba.
--SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900