<snip>
> > Further, connecting it to a dataset leaves those arrows on the caption
> > bar. Connecting it directly to the dataview, however, does not.
>
> I'm not sure what you mean here. Are you using VS 2003 or 2005? Are you
> talking about the WinForms DataGrid or the WebForms DataGrid?
2003, winforms.
> Well, not always. A DataGrid is a window into the in-memory representation
> of the original data. It could be a DataView or it could be a DataTable
> directly or it could be a DataSet that holds a DataTable.
Original? Why? AFAIK, the datagrid can change the data, now having two
sets, that are the orignal and the modified, and the datagrid shows the
modified.
> > A dataview is the resultset of a datatable
> > (as opposed to the design). A datatable can be filled in many ways. One
> > way is with a select statement. One way to run a select statement is
> > via the Fill() command of a dataadaptor.
>
> Not actually. A DataView holds no data whatsoever. It is simply a filtered
> view of the in-memory representation of the data.
Granted.
However, setting it to a datatable is the same thing as setting it to
the datatable's defaultview.
> >> So, you need to call the DataGrid's DataBind method to
> >> tell the grid to go and look at the data (specified in the DataSource
> >> property) and bind to it.
> >
> > When it is set it looks. Databind is not needed, as i expreessed
> > earlier.
>
> Again, I'll ask what version of .NET are you referring to? My responses are
> based on the 1.1 Framework, VS.NET 2003 and the WebForms DataGrid. In these
> versions, you MUST call .DataBind to get any data.
Ah, well, that explains it.
It's all so confusing.
<snip>
>
> > I still see no reason for databind.
>
> In a WinForms app, you would only need DataBind on the initial DataGrid
> population.
Nope. You never need to do it on winforms.
I read some more about it. The purpose of databindings has to do with
controls and returning values, like the bound column in Access. So, for
example, if a combo box shows one column but returns the value of
another, a databinding would need to be done to the column whose values
are wanted.
B.