Categories:
.NET (961)
C (387)
C++ (185)
CSS (84)
DBA (8)
General (31)
HTML (48)
Java (641)
JavaScript (220)
JSP (109)
JUnit (31)
MySQL (297)
Networking (10)
Oracle (562)
Perl (48)
Perl (9)
PHP (259)
PL/SQL (140)
RSS (51)
Software QA (28)
SQL Server (5)
Struts (20)
Unix (2)
Windows (3)
XHTML (199)
XML (59)
Other Resources:
What are the steps to follow to use Platform Invoke?
Managed Code and Unmanaged Code related ASP.NET - What are the steps to follow to use Platform Invoke?
✍: Guest
To use platform invoke, follow the following steps:
1. Import the System.Runtime.InteropServices namespace.
2. Declare the unmanaged procedure using the DllImport attribute or the Declare statement.
3. Map the data types of the procedures parameters to the equivalent .NET types.
4. Call the unmanaged procedure and test its return value for success.
5. If the procedure did not succeed, retrieve and handle the exception code using the Marshal object’s GetLastWin32Error method.
2009-03-31, 4249👍, 0💬
Popular Posts:
What's the output of the following program? And why? #include main() { typedef union { int a; char b...
WHat will be the result of the following code? #define TRUE 0 // some code while (TRUE) { // some co...
How can we format data inside DataGrid? Use the DataFormatString property.
How can I include comments in HTML? An HTML comment begins with "<!--", ends with "-->...
.NET INTERVIEW QUESTIONS - Where do you specify session state mode in ASP.NET ? The following code e...