hi im just i desparate need of some help here,
I have a MSHFlexgrid and im adding new records to the Database.
I cannot seem for the life of me get the grid to refresh unless I close and re-open the form. which I dont want to do!
I can see that the data has been added to the SQL table but once I add it, I cannot get the Flexgrid to show the newly added record
Ive even tried putting a button on the form to run the statemetn below and it doesnt refresh.
Now here's the odd bit.
If I update the records in the table then press the refresh button the records currently in the grid refrsh but still the new record is not shown!!!
Any ideas PLEASE!!
-----------------------------------------------
Dim oRSOrderDetReq As ADODB.Recordset
Dim strConnect As String
Dim strSQLDet As String
strConnect = INI_getString("String", "ConnectString1", App.Path & "\dataconn.ini")
strSQLDet = "Select ISBN, Description, Quantity ,UnitPrice, Discount, Discount_Type,Discount_Amount," & _
"Tax_Code,SalesTax, ExtSalesTax, ExtAmount,Location, Kit_Item,Weight_Ea, ExtWeight, OrderID, Row_ID, Date_Added from Orders_Detail where OrderID = " & frmOrders.OrderID.Text
Set oRSOrderDetReq = New Recordset
oRSOrderDetReq.Open strSQLDet, strConnect, adOpenKeyset, adLockOptimistic
Set MSHFlexOrdDetail.DataSource = oRSOrderDetReq
-------------------------------------------------------
thanks
brendan
I have a MSHFlexgrid and im adding new records to the Database.
I cannot seem for the life of me get the grid to refresh unless I close and re-open the form. which I dont want to do!
I can see that the data has been added to the SQL table but once I add it, I cannot get the Flexgrid to show the newly added record
Ive even tried putting a button on the form to run the statemetn below and it doesnt refresh.
Now here's the odd bit.
If I update the records in the table then press the refresh button the records currently in the grid refrsh but still the new record is not shown!!!
Any ideas PLEASE!!
-----------------------------------------------
Dim oRSOrderDetReq As ADODB.Recordset
Dim strConnect As String
Dim strSQLDet As String
strConnect = INI_getString("String", "ConnectString1", App.Path & "\dataconn.ini")
strSQLDet = "Select ISBN, Description, Quantity ,UnitPrice, Discount, Discount_Type,Discount_Amount," & _
"Tax_Code,SalesTax, ExtSalesTax, ExtAmount,Location, Kit_Item,Weight_Ea, ExtWeight, OrderID, Row_ID, Date_Added from Orders_Detail where OrderID = " & frmOrders.OrderID.Text
Set oRSOrderDetReq = New Recordset
oRSOrderDetReq.Open strSQLDet, strConnect, adOpenKeyset, adLockOptimistic
Set MSHFlexOrdDetail.DataSource = oRSOrderDetReq
-------------------------------------------------------
thanks
brendan