ReportServerCredentials.GetFormsCredentials 方法

返回指示在连接到报表服务器时是否会使用窗体身份验证的布尔值,以及有关用于身份验证的窗体凭据的信息。

命名空间:  Microsoft.Reporting.WinForms
程序集:  Microsoft.ReportViewer.WinForms(在 Microsoft.ReportViewer.WinForms.dll 中)

语法

声明
Public Function GetFormsCredentials ( _
    <OutAttribute> ByRef authCookie As Cookie, _
    <OutAttribute> ByRef userName As String, _
    <OutAttribute> ByRef password As String, _
    <OutAttribute> ByRef authority As String _
) As Boolean
用法
Dim instance As ReportServerCredentials
Dim authCookie As Cookie
Dim userName As String
Dim password As String
Dim authority As String
Dim returnValue As Boolean

returnValue = instance.GetFormsCredentials(authCookie, _
    userName, password, authority)
public bool GetFormsCredentials(
    out Cookie authCookie,
    out string userName,
    out string password,
    out string authority
)
public:
virtual bool GetFormsCredentials(
    [OutAttribute] Cookie^% authCookie, 
    [OutAttribute] String^% userName, 
    [OutAttribute] String^% password, 
    [OutAttribute] String^% authority
) sealed
abstract GetFormsCredentials : 
        authCookie:Cookie byref * 
        userName:string byref * 
        password:string byref * 
        authority:string byref -> bool 
override GetFormsCredentials : 
        authCookie:Cookie byref * 
        userName:string byref * 
        password:string byref * 
        authority:string byref -> bool 
public final function GetFormsCredentials(
    authCookie : Cookie, 
    userName : String, 
    password : String, 
    authority : String
) : boolean

参数

  • authCookie
    类型:System.Net.Cookie%
    [out] 报表服务器使用的身份验证 Cookie。
  • userName
    类型:System.String%
    [out] 将用于连接到报表服务器的用户名。

返回值

类型:System.Boolean
如果在连接到报表服务器时要使用窗体身份验证,则返回 true。有关用于窗体身份验证的凭据的信息通过方法调用中使用的 out 参数返回。

实现

IReportServerCredentials.GetFormsCredentials(Cookie%, String%, String%, String%)

请参阅

参考

ReportServerCredentials 类

Microsoft.Reporting.WinForms 命名空间