Announcement

Collapse
No announcement yet.

Spalte of type Btye() (Byte Array)

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Spalte of type Btye() (Byte Array)

    Hallo,

    ich möchte in einem Datatable Grafiken ablegen. Dazu habe ich folgende Anleitung für vb.net im Internet gefunden:

    ________________________________________
    Public Function MakeDataTable() As DataTable

    ' declare a DataTable to contain the program generated data
    Dim dataTable As New DataTable("Cells")

    ' create and add a Column
    Dim colWork As New DataColumn("Name", GetType(String))
    dataTable.Columns.Add(colWork)

    ' create and add a column
    colWork = New DataColumn("Picture", GetType(Byte()))
    dataTable.Columns.Add(colWork)
    __________________________________________

    Meine Übersetzung nach C# funktioniert bis zur zweiten Spalte:

    DataTable dataTable = new DataTable("Cells");

    DataColumn colWork = new DataColumn("Name", System.Type.GetType("System.String"));
    dataTable.Columns.Add(colWork);

    colWork = new DataColumn("Picture", System.Type.GetType("System.Byte"));
    dataTable.Columns.Add(colWork);

    Für die Grafiken brauche ich eine Spalte of type Btye() (Byte Array). Bisher ist es mir nicht gelungenen einen Typ dieser Art zu bekommen.

    Vielen Dank für die Unterstützung im Voraus,
    Albert

  • #2
    Hallo,
    mit Hilfe habe ich es gelöst.

    (byte [])

    Albert

    Comment

    Working...
    X