Help with Advanced Datagrid (repost)

B

Brad Shook

First of all thinks to Cor Ligthert for helping me with this last week.

If you wild like to read Cor's comments please refer to the posting from
10/14/2004 and 8:48AM "Help with Advanced Datagrid"

I am trying to bind one column of a datagrid to a seperate textbox and
the rest of the fields to a datagrid. the comments are too large to
fit in a datagrid so I created a textbox below the datagrid and need
it to hold the data for the current record selected in the datagrid.
Here is a part of the code.

'DataSetWellMobile1 is the dataset with all the data
'DGWellResults is the dtagrid I am binding the data to
'txtWellComments is the textbox that I need bound

Me.DataSetWellMobile1.Relations.Add( _
New DataRelation( _
relationName:="relWellInfo", _

parentColumn:=Me.DataSetWellMobile1.Tables("TblPeople").Columns("UniqueId"),
_

childColumn:=Me.DataSetWellMobile1.Tables("TblWellMobileInfo").Columns("Pers
onId"),
_
createConstraints:=True))

Me.DGWellResults.DataBindings.Add(New Binding("DataSource",
Me.DataSetWellMobile1.TblPeople.DefaultView, "relWellInfo"))

Me.txtWellComments.DataBindings.Add(New Binding("Text",
DataSetWellMobile1.TblPeople.DefaultView, "relWellInfo.Comments"))

The code binds everything but the currency manager does not change the
textbox to the next record when I select on the next record in the
datagrid.

The data structure is

Parent Datagrid
Child Datagrid
textbox linked to child datagrid

What am I missing.
Thanks,
Brad
 
C

Cor Ligthert

Brad,

I have tried this again but I cannot get the currencymanager do anything,
what related table I use or object I connect as filter to that.

I have searched Google for this and found one answer what I thought that was
about this. There was talked about a kind of bug by somebody who had
contacted Microsoft. However it was not clear if he had an answer and if the
answer did fit.

(The currencymanager stays forever on zero, a problem what I had seen before
however because of your question have again investigated).

You can go around this by not using the datarelations but the dataview with
filter, however than you have to do the adding of rows not using the *.

Maybe you can place this question as well in the newsgroup

microsoft.public.dotnet.framework.adonet

Can be that somebody there says, this is easy and than we both know the
answer because I am not as much as here however as well active in that
newsgroup.

Cor
 
B

Brad Shook

Thanks Cor. I will post this in another group. I agree with you in that I
think this is a bug.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top