mark trinidad
New member
- Joined
- Jul 1, 2016
- Messages
- 1
- Programming Experience
- 1-3
Dim db = New database
Dim dt As New DataTable
With db
.sqlStr = "Select itemprod_id as ProductID, item_name as BrandName, item_description as ItemDescreption, company_id as Company, quantity_stock as Stock, stock_alertcntr as alert, wprice as CompanyPrice, price as RetailPrice FROM items ORDER BY Item_name" 'query string
.sqlDa.SelectCommand = .sqlcm(.sqlStr, .connect) 'execute command
.sqlDa.Fill(.sqlDt) 'get results and store in sqldt
.close()
End With
dt = db.sqlDt
Return dt
my datagridview super slow showing 2000+ data from database
Dim dt As New DataTable
With db
.sqlStr = "Select itemprod_id as ProductID, item_name as BrandName, item_description as ItemDescreption, company_id as Company, quantity_stock as Stock, stock_alertcntr as alert, wprice as CompanyPrice, price as RetailPrice FROM items ORDER BY Item_name" 'query string
.sqlDa.SelectCommand = .sqlcm(.sqlStr, .connect) 'execute command
.sqlDa.Fill(.sqlDt) 'get results and store in sqldt
.close()
End With
dt = db.sqlDt
Return dt
my datagridview super slow showing 2000+ data from database