[StructLayout(LayoutKind.Sequential, CharSet=CharSet.Auto)]
struct TOOLTIPTEXT
{
public NMHDR hdr;
public IntPtr lpszText;
[MarshalAs(UnmanagedType.ByValTStr, SizeConst=80)]
public string szText;
public IntPtr hinst;
public int uFlags;
}
// ANSI version of the structure.
[StructLayout(LayoutKind.Sequential, CharSet=CharSet.Ansi)]
struct TOOLTIPTEXTA
{
public NMHDR hdr;
public IntPtr lpszText;
[MarshalAs(UnmanagedType.ByValTStr, SizeConst=80)]
public string szText;
public IntPtr hinst;
public int uFlags;
}
<StructLayout(LayoutKind.Sequential, CharSet=CharSet.Auto)> _
Structure TOOLTIPTEXT
Public hdr As NMHDR
Public lpszText As IntPtr
<MarshalAs(UnmanagedType.ByValTStr, SizeConst=80)> _
Public szText As String
Public hinst As IntPtr
Public uFlags As Integer
End Structure
' ANSI version of the structure.
<StructLayout(LayoutKind.Sequential, CharSet=CharSet.Ansi)> _
Structure TOOLTIPTEXTA
Public hdr As NMHDR
Public lpszText As IntPtr
<MarshalAs(UnmanagedType.ByValTStr, SizeConst=80)> _
Public szText As String
Public hinst As IntPtr
Public uFlags As Integer
End Structure