Bagikan melalui


DataSet.DataSetName Properti

Definisi

Mendapatkan atau mengatur nama saat ini DataSet.

public:
 property System::String ^ DataSetName { System::String ^ get(); void set(System::String ^ value); };
public string DataSetName { get; set; }
[System.Data.DataSysDescription("DataSetDataSetNameDescr")]
public string DataSetName { get; set; }
member this.DataSetName : string with get, set
[<System.Data.DataSysDescription("DataSetDataSetNameDescr")>]
member this.DataSetName : string with get, set
Public Property DataSetName As String

Nilai Properti

Nama DataSet.

Atribut

Contoh

Contoh berikut membuat baru DataSet dengan yang diberikan DataSetName.

private void CreateDataSet()
{
    DataSet dataSet = new DataSet("SuppliersProducts");
    Console.WriteLine(dataSet.DataSetName);

    // Add a DataTable.
    dataSet.Tables.Add(new DataTable("Suppliers"));

    // Add a DataColumn to the DataTable.
    dataSet.Tables["Suppliers"].Columns.Add
        (new DataColumn("CompanyName",
        System.Type.GetType("System.String")));
}
Private Sub CreateDataSet() 
    Dim dataSet As DataSet
    dataSet = New DataSet("SuppliersProducts")
    Console.WriteLine(dataSet.DataSetName)
End Sub

Berlaku untuk

Lihat juga