473,809 Members | 2,809 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Databinding questions

Hi Al

When I have a text box, list box, and a datagrid, how does a CurrencyManager relate to all these controls(seeing as though the datagrid uses Complex binding and textbox and list box use simple bound. So for example if I have a text box, list box and a Datagrid on a windows form, and I want to navigate the records in a dataset(and we must not forget the child records from the child tables aswell!) How do I create the CurrencyManager to handle this navigation and how do I "bind" this currencymanager to all the controls on my form?(or is a CurrencyManager created for me?) , AND is it possible to have one control belonging to more that one CurrencyManager ?

Can someone explain this to me aor provide me with links to good information about thi

I hope that my explanation was good enough to understand:

Thanks alot for any of your help on this. I just want to learn more about this "DataBindin g" story,because I do not understand it very well

Kevin
Nov 15 '05 #1
1 1390
Hi Kevin,
How do I create the CurrencyManager to handle this navigation and how do I "bind" this currencymanager toall the controls on my form?(or is a CurrencyManager created for me?)
It is created for you behind the scenes when you bind a control to a
datasource. Your responsibility is to specify correct DataSource and
DisplayMember (DataMember for the DataGrid control).
AND is it possible to have one control belonging to more that one CurrencyManager ?

No, but it is possible to bind several controls to the same list (determined
by the DataSource and DisplayMember property values) and all these controls
will share the same position in the list.
Can someone explain this to me aor provide me with links to good information about this

I believe MSDN has enough information on data binding in Windows Forms.
Please refer to topics such as
"Data Binding and Windows Forms" and "Windows Forms Data Architecture" in
Visual Basic and Visual C# Concepts.

--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://www.x-unity.net/teststudio.aspx
Bring the power of unit testing to VS .NET IDE

"Kevin" <an*******@disc ussions.microso ft.com> wrote in message
news:3C******** *************** ***********@mic rosoft.com... Hi All

When I have a text box, list box, and a datagrid, how does a CurrencyManager relate to all these controls(seeing as though the datagrid
uses Complex binding and textbox and list box use simple bound. So for
example if I have a text box, list box and a Datagrid on a windows form, and
I want to navigate the records in a dataset(and we must not forget the child
records from the child tables aswell!) How do I create the CurrencyManager
to handle this navigation and how do I "bind" this currencymanager to all
the controls on my form?(or is a CurrencyManager created for me?) , AND is
it possible to have one control belonging to more that one CurrencyManager ?
Can someone explain this to me aor provide me with links to good information about this
I hope that my explanation was good enough to understand:)

Thanks alot for any of your help on this. I just want to learn more about this "DataBindin g" story,because I do not understand it very well.
Kevin


Nov 15 '05 #2

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

Similar topics

1
1351
by: GMG | last post by:
By providing a DTD in an XML document which is bound to HTML controls, Internet Explorer will automatically format the display of the date fields. For example 2004-08-03T00:00:00 will be displayed as 08/03/2004. It is a fantastic feature, but how does it determine which format to display it in ? The format that is being displayed on the samples I am looking at does not match my regional settings. All the dates are displayed in US format...
3
4633
by: Michael | last post by:
I've hooked up a TextBox's Text property with the property of a class. However, when invalid data is entered, the data binding updates the object immediately. Is there anyway to prevent this from happening? Or should I just re-assign the value to the object directly in this case? Thanks, Michael
0
1525
by: Richard | last post by:
Hi, I'm having issues with DataBinding. I have a Form with two data bound comboboxes on it. When you select something in one combobox I may {or may not} want to change the selected item in the other combobox. For reasons beyond the scope of this post I need to change the second comboboxe's selected index from within a ColumnChanging event handler. So, inside a ColumnChanging event handler I change the value of the column that is bound to...
2
2726
by: Martin | last post by:
Hi, Please can somebody explain how databinding is done on a checkbox list. I have the follwoing code which I would have thought was enough to databind a checkbox, but apparently not. The data is coming from an sql server database "Name" is a text feild "Valid" is a bit field
2
1689
by: Mr Newbie | last post by:
Ive got the basic idea behind DataBinding Expressions, but I have a couple of questions, Ok its four actually :) Q1.) It would appear that if you use Page.DataBind that all child controls and the page get bound to their respective DataSources, is this correct ? and if so why would you need to individually bind controls, why not jsut use Page.DataBind everytime?, Im sure there is a good reason why not but I cant think of one at the...
3
1107
by: Kostas Kousinovalis | last post by:
Hello Is it so difficult to make a databound form or am I somewhere wrong? First I create a SQL DataAdapter with a connection to Northwid Products VB creates a SQLConnection1 Then I'm creating a Dataset
8
2189
by: GaryDean | last post by:
We have been noticing that questions on vs.2005/2.0 don't appear to get much in answers so I'm reposting some questions posted by some of the programmers here in our organization that never got answered... In 1.1 we always did our own myDataAdapter.fills and we liked that control for lots of good reasons. Now the new DataSource (or is it a TableAdapter:Dataset) automatically fills the Gridview. How can we control that fill? In a...
1
2773
by: Sergei Shelukhin | last post by:
I have the following problem with gridview. I use MySQL database that has Russian characters in cp1251 encoding, and I get ????????s instead of Russian characters on all my ASP.NET pages. To fix this, I use helper function to get database connection, it goes: public static OdbcConnection GetConnection() { OdbcConnection cn = new OdbcConnection(ConfigurationManager.ConnectionStrings.ConnectionString); OdbcCommand cmd = new...
0
203
by: DLI | last post by:
Scenario: I have a form and two text boxes and one datagrid. I have a dataset composed of two tables Questions (QuestionID, QuestionText) Answers (QuestionID, AnswerText) there is a one to many relationship between Questions and Answers defined by this Relation (QuestionAnswer) in the dataset ds
2
2838
by: Infog | last post by:
I have a database in Access 2007, and a GUI in VB.NET 3.5. Where should I go to start learning about databinding, and how to have the front end manipulate the database? I would love to find some learning resources for coding and concepts that is more concise/condensed than random forums, Google, and the MSDN developer references. Most of these questions will be about databinding, datasets, querying, etc. The several general questions I...
0
10376
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10383
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10120
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9200
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7661
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6881
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5550
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5688
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4332
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

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.