Imports System.Data.OleDb
Public Class frm_deliveryrate
'Public connString As String = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=db.accdb"
Dim conn As New OleDbConnection
Dim myqry As String = Nothing
Dim mycmd As New OleDbCommand
Dim mydr As OleDbDataReader
Dim str As String = Nothing
Private Sub frm_deliveryrate_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Call LVsettings()
Call ConnToDB()
Call FillListview()
Call Set1()
End Sub
#Region "FillListView"
Sub FillListview()
LV.Items.Clear()
myqry = "SELECT * from DeliveryRate ORDER BY ID_Deliverly ASC"
mycmd = New OleDbCommand(myqry, conn)
mydr = mycmd.ExecuteReader
While mydr.Read
With LV
.Items.Add(mydr("ID_Deliverly"))
With .Items(.Items.Count - 1).SubItems
.Add(mydr("LeaseContainer"))
.Add(mydr("KMPrice"))
End With
End With
End While
End Sub
#End Region