I wasnt to display the contents of a database in a datagrid control. Any ideas?
Printable View
I wasnt to display the contents of a database in a datagrid control. Any ideas?
What kind of database control are you using??
-Kayoca Mortation
If you are using a MSHFlexgrid then just assign a recordset to the datasource property of the flexgrid and it should populate it without any problem:
example:
'
' Call stored procedure with customer number from combo box
'
Set lrs_history= getCustomerHistory(dComboHistory.BoundText)
' Call deUSD.populateGrid(dComboHistory.BoundText)
Set lrs_history = deUSD.rspopulateGrid
'
' Assign recordset to flexgrid
'
Set MSHFlexGrid1.DataSource = lrs_history
to make our life easy you can just bound the DBGrid to a Data Control but iff you wish to display a particular data field record, then you may need to use the SELECT statement in the RecordSource property of the Data Control.
hope this can help