25 February 2009
Solution to Method has no implementation (no RVA) Error
If you get this exception
System.TypeLoadException: Could not load type ‘x’ from assembly 'xx, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' because the method 'SendMessage' has no implementation (no RVA).
Make sure you have a DllImport attribute for the method.
This…
1: public static extern IntPtr SendMessage(IntPtr w, uint m, IntPtr p1, IntPtr p2);
Becomes this…
1: [DllImport("user32.dll")] 2: public static extern IntPtr SendMessage(IntPtr w, uint m, IntPtr p1, IntPtr p2);
Technorati Tags: Solution,Error,exception,System,TypeLoadException,Version,Culture,PublicKeyToken,SendMessage,DllImport,IntPtr,extern
Comment Notification
If you would like to receive an email when updates are made to this post, please register here
Subscribe to this post's comments using
Comment Policy: No HTML allowed. URIs and line breaks are converted automatically. Your e–mail address will not show up on any public page.