Solved

To use Data Bound controls or not ?

Posted on 1998-08-03
10
165 Views
Last Modified: 2010-05-03
From books, DBList, DBCombo and also the List, Combo separately could utilize DAO recordsets.  Which provides more accuracy even though more code is required ? Which provides greater data access speed ?  Which do you prefer ?
0
Comment
Question by:optical
10 Comments
 
LVL 2

Expert Comment

by:percosolator
ID: 1467694
In my experience, data controls are evil. <g>  They have the tendency to "snap-back" to the first record in the recordset once you update a record (from what I remember), and what you change in the control directly updates the data (again, from what I remember. There are probably ways of dealing with these behaviors, but I never pursued them--data-bound controls scared me!

One advantage of data-bound controls, though,  is that they require less code.

I've used DAO and RDO and they seem to require the same amount of coding.

But I would recommend RDO for several reasons, the not the least being that RDO seems to be the successor to DAO, it's also faster than both data-bound (which are a dog) and DAO; it allows batch processing as well as asynchronous transactions, and it is event-driven.

Look into it for yourself, run some comparable tests, there's enough information in Books Online to help you decide.

Doug
0
 
LVL 4

Expert Comment

by:tomook
ID: 1467695
Here are some rambling thoughts. It has been a Monday and I am writing this with a beer in my hand. Pardon any incoherency.

IMHO, in DAO it is a toss-up. If your form is based on one table, you can get some decent performance improvement going unbound (because you can use a table-type recorset), but I typically have only trivial forms which are based on one table. Searching through multiple table-type recordsets is almost always less efficient than using a dynaset on a query with a join. If you have large numbers of users, unbound will help increase the maximum number of effective users. Of course, if you have a large number of users, why are you using DAO?

As for ADO & RDO I definitely prefer working unbound. You can manage your connections much better manually than with data controls.
0
 
LVL 2

Expert Comment

by:percosolator
ID: 1467696
tomook.... I hear the beer.  It is a Monday indeed.

I agree with the management of your connections.  You always know precisely what's what.
0
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 9

Expert Comment

by:Dalin
ID: 1467697
My opinion is, that it depends on your comfort level and the task you are undertaking.

Although I am using DAO in most case now, I had used data control and bounded control for my first couple of years, and I had not experienced significant trouble.  

However, DAO (and RDO) gives you more capbility and flexibility, although it required significant more code.

If you feel more confortable with coding, and have a good idea as how to doing it, by all means use DAO.  If you are relatively new in VB database programming, I would suggest you start with data control, but do pay attention to some of the behaviors of data control.
Regards


0
 
LVL 2

Expert Comment

by:percosolator
ID: 1467698
tomook.... I hear the beer.  It is a Monday indeed.

I agree with the management of your connections.  You always know precisely what's what.
0
 

Expert Comment

by:vinoopauls
ID: 1467699
  The data control is an anathema to me. Very difficult to understand its behaviour. I find it
always convenient to use the unbound controls. The flexibilty available easily offsets the
difficulty in coding. Moreover complex insert update and select queries is easier to handle
in the unbound mode.
0
 

Expert Comment

by:chitnis
ID: 1467700
Id depends on the type of application u are developing.For a 3tier client server application data bound controls are a strict no-no as they take a lot of time to make connection and fetchn data.RDO is better.For stand alone apps.Data bound controls are better.
0
 
LVL 2

Expert Comment

by:percosolator
ID: 1467701
Data-bound controls completely violate three-tier architecture.
0
 
LVL 2

Expert Comment

by:Veroland
ID: 1467702
NEVER USE DATA CONTROLS !!!!!!!!!!!
0
 
LVL 1

Accepted Solution

by:
DQ earned 50 total points
ID: 1467703
IF your application is relatively simple, use data control give you a quick start, with reasonably satisfactory results. It will help you learn. If you are dealing with a remote date source, with non native database, doing a lot of SQL query, datacontrol is not suitable.

Based on your question, I think you can start with data control. When you get more skilled with coding, migrate to DAO.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
using web browser with BING 40 132
Excel Automation VBA 19 91
converting visio 2010 to powerpoint 2010  - formatting issues 5 93
Publisher:   Unknown     VB.exe Application 1 28
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question