coredll is for smart devices, not desktop Windows. Therefore, this information only applies to code using the .NET Compact Framework. To see if information for DeviceIOControl in other DLLs exists, click on Find References to the right.
[DllImport("coredll.dll", EntryPoint="DeviceIoControl", SetLastError=true)]
internal static extern int DeviceIoControlCE(
ref int lpBytesReturned,
<DllImport("CoreDll.dll")> Function DeviceIoControl(ByVal hDevice As Integer, ByVal dwIoControlCode As Integer, _
ByVal lpInBuffer As String, ByVal nInBufferSize As Integer, _
ByVal lpOutBuffer() As Byte, ByVal nOutBufferSize As Integer, _
ByRef lpBytesReturned As Integer, ByVal lpOverlapped As Integer) As Integer
An IntPtr is a pointer to a memory location (unmanaged) that adapts to the platform it is running on (64-bit, etc.) UNLIKE a standard int/Integer. You should always use this type for unmanaged calls that require it, even though an int will appear to work on your development machine.
1/13/2008 11:00:13 AM - tsahi-22.214.171.124
Please edit this page!
Do you have...
helpful tips or sample code to share for using this API in managed code?
corrections to the existing content?
variations of the signature you want to share?
additional languages you want to include?
Select "Edit This Page" on the right hand toolbar and edit it! Or add new pages containing supporting types needed for this API (structures, delegates, and more).