|
-
Jun 25th, 2024, 03:19 PM
#1
Thread Starter
Hyperactive Member
[RESOLVED] Binding Underlying Controls of UserControls to Database
Hi, Consider you already filled a data grid view with a table of database file and you want to changeover from conventional "Tabular view" to sort of "Cellular view" which is a table layout panel with UserControls programmatically added in its cells.
This UserControl has TextBoxes, ProgressBars, Labels and so on next to a Public property called UniqueID to pass which row it supposed to show. Formerly CellValueChanged event with a bulky parallel for did the matter but the goal is to achieve a bidirectional relation meaning that changing a value on cellular view will also apply on data grid view (and dataset/adapter update later) right before new data comes (Causing your new data to discard and revert to original DGV given value).
What I tried: Adding a BindingNavigator to UserControl and link it to database won't do anything. Its records are always zero and linking it to corresponding table databinding on main form forces all UserControls to follow only one record.
Is there a way to achieve such desire?
Last edited by pourkascheff; Jul 8th, 2024 at 03:27 PM.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|