IConnectionInfo.IntegratedSecurity Property
Determines whether the database connection will use integrated security.
Namespace CrystalDecisions.Shared Assembly CrystalDecisions.Shared (CrystalDecisions.Shared.dll)
Syntax
'Declaration
Public Overrideable MustInherit Property IntegratedSecurity As Boolean
public virtual abstract bool IntegratedSecurity {get; set;}
Example
This example shows how to set the logon information for IConnectionInfo.
'Declaration
Private Sub SetLogOnInfo2(ByVal myReportViewer As CrystalReportViewer, ByVal userID As String, ByVal reportName As String, _
ByVal password As String, ByVal databaseName As String, ByVal serverName As String, ByVal tableName As String)
Dim myLogOnInfo As New TableLogOnInfo
Dim myIConnectionInfo As IConnectionInfo
myIConnectionInfo = myLogOnInfo.ConnectionInfo
myIConnectionInfo.SetConnection(serverName, databaseName, userID, password)
myIConnectionInfo.IntegratedSecurity = True
myLogOnInfo.TableName = tableName
myLogOnInfo.ReportName = reportName
Dim myTableLogOnInfos As New TableLogOnInfos
myTableLogOnInfos.Add(myLogOnInfo)
myReportViewer.LogOnInfo = myTableLogOnInfos
End Sub
private void SetLogOnInfo2(CrystalReportViewer reportViewer, string userID, string reportName,
string password, string databaseName, string serverName, string tableName)
{
TableLogOnInfo logOnInfo = new TableLogOnInfo();
IConnectionInfo iConnectionInfo = (IConnectionInfo)logOnInfo.ConnectionInfo;
iConnectionInfo.SetConnection(serverName, databaseName, userID, password);
iConnectionInfo.IntegratedSecurity = true;
logOnInfo.TableName = tableName;
logOnInfo.ReportName = reportName;
TableLogOnInfos tableLogOnInfos = new TableLogOnInfos();
tableLogOnInfos.Add(logOnInfo);
reportViewer.LogOnInfo = tableLogOnInfos;
}
Version Information
Crystal Reports Basic for Visual Studio 2008
Supported since: Crystal Reports .NET XI
See Also
Reference
IConnectionInfo Interface
IConnectionInfo Members
CrystalDecisions.Shared Namespace