我从 pinvoke 网站复制并粘贴了以下 VB.NET 结构。
http://www.pinvoke.net/default.aspx/Structures/BITMAPINFOHEADER.html
但是,当我将它粘贴到这样的模块名称下的模块中时,VB.NET 告诉我需要声明:
Option Strict Off
Option Explicit On
Imports System
Imports System.Diagnostics
Imports System.Drawing
Imports System.Drawing.Drawing2D
Imports System.Runtime.InteropServices
Imports System.Windows.Forms
Module modDrawing
StructLayout(LayoutKind.Explicit)>Public Structure BITMAPINFOHEADER
<FieldOffset(0)> Public biSize As Int32
<FieldOffset(4)> Public biWidth As Int32
<FieldOffset(8)> Public biHeight As Int32
<FieldOffset(12)> Public biPlanes As Int16
<FieldOffset(14)> Public biBitCount As Int16
<FieldOffset(16)> Public biCompression As Int32
<FieldOffset(20)> Public biSizeImage As Int32
<FieldOffset(24)> Public biXPelsperMeter As Int32
<FieldOffset(28)> Public biYPelsPerMeter As Int32
<FieldOffset(32)> Public biClrUsed As Int32
<FieldOffset(36)> Public biClrImportant As Int32
End Structure
请问我哪里做错了?非常感谢你。