locked
Help to read into Database (vb code) RRS feed

  • Question

  • User1717218719 posted

    I am unsure as to how to read into database any help would be great

    Imports System.Data.SqlClient
    
    Public Class Form1
    
    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    
    '-- create datatable X2
    
    Dim Datatbl As New DataTable
    
     Datatbl.Columns.Add("X", GetType(String))
    
    
    
    '-- Read into datatable
    
    
    
    HELP WITH THIS PART PLEAESE
    

     

    Thursday, May 9, 2019 11:43 AM

Answers

  • User1717218719 posted

    I managed to find the solution:

    '--Read into database
    
    Dim row As DataRow
    
    row = Datatbl.NewRow()
    
    row("X") = strRedLne.Substring(5, 7)
    

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, May 10, 2019 10:34 AM

All replies