1. You need to add reference to System.Runtime.InteropServices; for this
2. All methods marked with the DllImport attribute must be marked as public static extern
Extern:-
Use the extern modifier in a method declaration to indicate that the method is implemented externally. A common use of the extern modifier is with the DllImport attribute.
No comments:
Post a Comment