473,385 Members | 1,353 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

BindingContext problem (Maybe)

I have a strange problem. In my form there is a grid(dgBC) and there
is one checkBox column who is editable. When i make a change on a row,
i must select another row, if i don't the changes will not be saved.

Any idea ??

Thx
DoOmX

(I shrink the code because there is to much class involved)
=======================================
In the Form :
---------------

Private _estimation As CDataEstimation = Nothing

Me._estimation = New CDataEstimation(key, Nothing, Me.BindingContext,
Me._cnx)

Dim dv As DataView = Me._estimation.Table.DefaultView
dv.AllowNew = False
dv.AllowEdit = True
dv.AllowDelete = False

Me.dgBC.DataSource = Me._estimation.Table

=================================================
Class CData (Base)
------------------
Protected Sub New(ByVal instSelect As String, ByVal posCh As
EventHandler, _
ByVal contexte As BindingContext, ByVal cnx As
CConnexion)

Me.m_cnx = cnx
Me.m_dt = New DataTable
Me.m_adap = New OleDbDataAdapter(instSelect, cnx.ConnexionString)

Me.m_adap.Fill(Me.m_dt)
Me.m_lien = New CDbLiaisons(contexte.Item(m_dt), posCh, m_adap)
Me._contexte = contexte
End Sub
=================================================
Class CDataEstimation
---------------------
Private Const sql As String = "Select * from Projets_Est_P where
pepNoProj = {0}"

Public Sub New(ByVal noProjet As Integer, ByVal posCh As EventHandler,
ByVal contexte As BindingContext, ByVal cnx As CConnexion)
MyBase.New(String.Format(sql, noProjet), posCh, contexte, cnx)

End Sub

Note Cdbliaison is a perfect Class (Tested by more than 150 persons)
so there is no Bugs there.
Nov 21 '05 #1
0 844

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: zee | last post by:
Hi, Could anybody please tell me why my web application refuses when I use BindingContext. I am selecting from a database and if (this.BindingContext.Count==0)...
0
by: Peter | last post by:
Hi, I'm developing a program in MDI style I've got 2 froms MDIForm (parent form) Form2 (child form with dataGrid1 and myDataSet)
1
by: D. Yates | last post by:
Hi, I retrieved the employee table from the Pubs database into a single dataset called, dataSet12. I dropped two textbox controls and a datagrid control onto the same form and bound the...
1
by: Joe Reggae | last post by:
Hello, I'm a little weak in understanding concepts surrounding currency and binding context and appreciate advice in getting some grids to bind (in sync) to three related tables. ...
0
by: Nathan Carroll | last post by:
Attempting to eliminate flicker showing (form) and hiding seems to have no effect as I have it below. if I move the lines: Me.Show() Me.ShowInTaskbar = True f.Close() to the end of the...
1
by: Edwin | last post by:
Hi, I created a dataform with the data form wizard which created some textboxes and 1 checkbox. When I add a row (see section "Add Row" for code) the newly added is not accessible. A label...
0
by: Donald | last post by:
Mostly, I get the currencymanager from the form.bindingcontext property. but I found that I can aslo get the same currencymanager from a textbox.bindingcontext, even though this textbox does not...
0
by: nina98765 | last post by:
Hi all I have a data-bound Windows form bound to a strongly-typed dataset. Upon opening the form, I would like to Find a specific record based on a parameter I've passed to the form, and display...
6
by: MeowCow | last post by:
I have created a UserControl that encapsulates a third party data grid. My goal was to create my own DataSource and DataMember properties that forward the binding to the third party grid, then use...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.