Check out the formatting tips on the right for help formatting and making links.
Use the template below then delete this header:
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct CREDUI_INFO
{
public int cbSize;
public IntPtr hwndParent;
public string pszMessageText;
public string pszCaptionText;
public IntPtr hbmBanner;
}
<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)> _
Public Structure CREDUI_INFO
Public cbSize As Integer
Public hwndParent As IntPtr
Public pszMessageText As String
Public pszCaptionText As String
Public hbmBanner As IntPtr
End Structure
None.
- Removed "[MarshalAs(UnmanagedType.LPWStr)]" attributes on pswMessageText and pszCaptionText.
These are no longer needed as CredUIPromptForCredentials has been modified to remove the explicit Unicode version.