Search
Module:
Directory

   Desktop Functions:

   Smart Device Functions:


Show Recent Changes
Subscribe (RSS)
Misc. Pages
Comments
FAQ
Helpful Tools
Playground
Suggested Reading
Website TODO List
Support Forum
Download Visual Studio Add-In

Terms of Use
Privacy Policy
IAuthenticate (Interfaces)
 
.
Summary
This interface is implemented by the client application to provide the URL moniker with information to authenticate the user.

C# Definition:

[ComImport]
[Guid("79EAC9D0-BAF9-11CE-8C82-00AA004BA90B")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
interface IAuthenticate {
   [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
   void Authenticate(IntPtr phwnd,
    [MarshalAs(UnmanagedType.LPWStr)] ref string pszUsername,
    [MarshalAs(UnmanagedType.LPWStr)] ref string pszPassword);
}

VB Definition:

<ComImport> _
<Guid("79EAC9D0-BAF9-11CE-8C82-00AA004BA90B")> _
<InterfaceType(ComInterfaceType.InterfaceIsIUnknown)>
Interface IAuthenticate
   <MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)>
   Sub Authenticate(IntPtr phwnd,
    <MarshalAs(UnmanagedType.LPWStr)> ByRef string pszUsername,
    <MarshalAs(UnmanagedType.LPWStr)> ByRef string pszPassword)
End Interface

User-Defined Types:

None.

Notes:

    Example:
    [ClassInterface(ClassInterfaceType.None)]
    public class Downloader : IBindStatusCallback, IDisposable, IAuthenticate
    {
    public void Download()
    {
    URLDownloadToFile(IntPtr.Zero, SourcePath , LocalPath ,0,(IBindStatusCallback)this);
    }
    /// <summary>
    /// Authenticates the specified user.
    /// </summary>
    /// <param name="phwnd">The HWND of the parent window for a default user interface.</param>
    /// <param name="pszUsername">The username to use for authentication.
    ///Client should also set phwnd to zero.</param>
    /// <param name="pszPassword">The password.</param>
    public void Authenticate(IntPtr phwnd, ref string pszUsername, ref string pszPassword)
    {
        // Downloader.Authenticate implementation
        phwnd = IntPtr.Zero;
        pszUsername = "ProxyUserName";
        pszPassword = "ProxyPassword";
    }
    }

Documentation

Please edit this page!

Do you have...

  • helpful tips?
  • corrections to the existing content?
  • alternate definitions?
  • additional languages you want to include?

Select "Edit This Page" on the right hand toolbar and edit it! Or add new pages containing any supporting types needed.

 
Access PInvoke.net directly from VS:
Terms of Use
Edit This Page
Find References
Show Printable Version
Revisions