Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

First cell empty in Datagrid

Status
Not open for further replies.

custsoft

Programmer
Aug 29, 2000
41
I use VB6, ADO 2.5. I have an ADO data control and a datagrid. Originally, the connection string and the record source properties were in the data control and things worked fine. I changed the connection string and record source to be set by the program. Now the first cell of the datagrid is empty when the database field is not. I suspect the connection string but it looks the same as what was in the data control property. Following is the code that I use in the program:
Dim rs As New ADODB.Recordset
rs.Open "select * from addresschg", TaxCN, adOpenStatic, adLockOptimistic
frmBrowse.adodcBrowse.CommandType = adCmdText
Set frmBrowse.adodcBrowse.Recordset = rs
frmBrowse.Show vbModal
TaxCn is the connection string.
I saw a reference to this problem in another question but no solution was given. Has anyone run into this? Thanks for your help. Joe
 
Just FYI,
Originally, opened the record set and then did a form show. I put the opening of the recod set in the activate section of the form and then the first cell was not blank. Joe.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top