We have a VB6 apps using DataGrid.
We have manage to show the grid with the SQL data. We need to add the Headers & format the sales.
- We set the form
- add the ADODC object
- at form load() we set the select as follows (which displays perfectly on the form):
Private Sub Form_Load()
Dim sSql As String
sSql = "select Departmment, Region, Sales from Territorial"
adocTerritorial.ConnectionString = cnn
adocTerritorial.RecordSource = sSql
We need to custiomize title and format Sales to $xxx.xx