• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 241
  • Last Modified:

Data Binding Problem

I have an ADO data control with a grid and textboxes bound to it.  Everything works fine when running XP, but when running 2000, the grid retrieves the data but the textboxes don't.

   With mconnTest
      .CursorLocation = adUseServer
      .ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;" & _
                          "Persist Security Info=False;" & _
                          "Data Source=" & DatabaseName()
      .Mode = adModeReadWrite
      .Open
   End With

   mrsTimecards.Open "SELECT * FROM Timecards", mconnTest, adOpenKeyset, adLockOptimistic

   Set datTimecards.Recordset = mrsTimecards
   datTimecards.Recordset.Requery


I also tried bypassing the data control and binding the controls directly to the recordset:

   Set grdTimecards.DataSource = mrsTimecards

   Set txtEmployeeName.DataSource = mrsTimecards

   txtEmployeeName.DataField = "EmployeeName"

which also works with XP but not with 2000.  I have service packed 2000 and installed the latest MDAC and Jet Components.  Still no dice.

MSADODC.OCX and MSBIND.DLL have been installed and registered.

I have also tried using a client-side cursor with no luck.

0
northeyk
Asked:
northeyk
  • 9
  • 8
1 Solution
 
leonstrykerCommented:
Stop using ADODC, use ADO directly.

Leon
0
 
northeykAuthor Commented:
As posted earlier, I tried binding directly to the recordset (without ADODC) with the same results.

   Set grdTimecards.DataSource = mrsTimecards

   Set txtEmployeeName.DataSource = mrsTimecards

This works with XP but not with 2000.
0
 
leonstrykerCommented:
When you tried doing this directly did you remove all references to the ADODC?

Leon
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
northeykAuthor Commented:
Yes.  It doesn't seem to matter either way, but yes - I removed all references to datTimecards with the same results.  I even removed it from the project to make sure.

My code works perfectly on XP - not only on my development PC, but also the client PC's (I've tested six).  They have two PC's running 2000 which have the problem.  I have a 2000 box here which I use for testing.  The problem exists here too.
0
 
leonstrykerCommented:
> I have service packed 2000 and installed the latest MDAC

Which versions do you have on the 2000 machine and which on XP?
0
 
northeykAuthor Commented:
Win2K: SP3,  WinXP: SP2.  MDAC: 2.8   Jet 4.0 SP8.
0
 
leonstrykerCommented:
Do you have MDAC: 2.8   on both?
0
 
northeykAuthor Commented:
Yes.  I have also tried it with all versions of MDAC from 2.5 on and with Jet Components SP3 and on.
0
 
leonstrykerCommented:
Have you tried compiling the program in 2000 enviroment or running it uncompilied in 2000 to debug it?
0
 
northeykAuthor Commented:
I just tried that.  I get Error 545 - unable to bind to field or datamember.

I have created a simple test app that will show the problem:

http://northey.com/download/test.zip

  * all files scanned with latest symantec definitions

If you're running XP, you will notice that all's fine.
0
 
leonstrykerCommented:
Actually I am running 2000.  Both versions worked for me.  I am using MDAC 2.6.  I had to uncheck the Missing reference to 2.8 and setup reference to 2.6

Leon
0
 
northeykAuthor Commented:
I just tried that with no success.  I will re-image my 2000 box and with a vanilla image and re-build with MDAC 2.6.  I'll keep you posted.  Thanks for the tip.
0
 
leonstrykerCommented:
Ok, let me know.

Leon
0
 
leonstrykerCommented:
Just tried it on XP with MDAC 2.6 and it worked.
0
 
northeykAuthor Commented:
No luck.  I have tried referencing 2.5, 2.6, 2.7 and 2.8 with no success.

I think the problem might be with msbind.dll.  Can you please tell me the version and date stamp on yours.  The one I'm installing is 6.1.97.82 dated Feb 23, 2004.
0
 
leonstrykerCommented:
On 2000 its 6.00.8862 July 15, 2000

On XP its 6.0.88.62 May 11, 2000

Leon
0
 
northeykAuthor Commented:
MSBIND.DLL has a dependency file - MSSTDFMT.DLL.  This file must be installed and registered on the Win2K PC's.
0

Featured Post

[Webinar On Demand] Database Backup and Recovery

Does your company store data on premises, off site, in the cloud, or a combination of these? If you answered “yes”, you need a data backup recovery plan that fits each and every platform. Watch now as as Percona teaches us how to build agile data backup recovery plan.

  • 9
  • 8
Tackle projects and never again get stuck behind a technical roadblock.
Join Now