[dba-VB] Bound form - vb.net

Griffiths, Richard R.Griffiths at bury.gov.uk
Thu Apr 20 03:47:23 CDT 2006


You can bind to various objects such as datasets and your business
I initially started binding to a dataset but quickly moved on to binding
to my class objects and this offers huge power IMO as you can bind to
all properties in your class and my class objects handles all the
updates to the BE db.

So in my form I would call BindFields which does something like this

	With tbLastName.Databindings
	end with
	bm = Me.BindingContext(myClassObject)	(bm is
bindingmanagerbase object)

For multiple records I would use an Array List to hold all my class
objects (records)

	With tbLastName.Databindings
	end with
	bm = Me.BindingContext(myArrayList)	(bm is
bindingmanagerbase object)

I know there is more to discuss in the area (such as using a strongly
typed collection class to hold my class object) but...



-----Original Message-----
From: dba-vb-bounces at databaseadvisors.com
[mailto:dba-vb-bounces at databaseadvisors.com] On Behalf Of Kath Pelletti
Sent: 19 April 2006 00:22
To: Access D Normal List; AccessD VB List
Subject: [dba-VB] Bound form - vb.net

(Cross posted to AccessD and AccessVB)

I can see that there are a few ways of working with data in vb.net on a
form. (My data in in Sql Server 2005 db)

But can someone tell me how they would *normally* bind data to a form
and display:

- A single record, or

- Multiple records, like in an Access continuous form.


Kath Pelletti
dba-VB mailing list
dba-VB at databaseadvisors.com

More information about the dba-VB mailing list