FlexReport for WinForms
ConnectionString プロパティ (DataSource)


C1.Report アセンブリ > C1.Report 名前空間 > DataSource クラス : ConnectionString プロパティ
Gets or sets the connection string used to open a database.
シンタックス
'宣言
 
Public Property ConnectionString As System.String
'使用法
 
Dim instance As DataSource
Dim value As System.String
 
instance.ConnectionString = value
 
value = instance.ConnectionString
public System.string ConnectionString {get; set;}
解説

This property is used by the DataSource class to load the report data.

While ConnectionString specifies the database that contains the data, RecordSource specifies which table, stored procedure, or Sql command to use for retrieving the data.

The syntax of ConnectionString is determined by the type of the data provider used by DataSource. For example if DataProvider is DataProvider.OLEDB then ConnectionString should use syntax used in OleDbConnection, if DataProvider is DataProvider.XmlFile, it should contain the name of the XML file, and so on.

If you want to use a different type of connection (e.g. System.Data.SqlClient.SqlConnection, or if your application already has the data available in a System.Data.DataTable object, you can assign the data directly to the Recordset property.

参照

参照

DataSource クラス
DataSource メンバ