473,503 Members | 722 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

what does databind do

hey all,

i was working on a formview and when i pressed my custom edit button to put
the formview in edit mode, i then, recursively loop thru the page controls
and see all the controls such as textboxes and other input controls.

well, when i press my custom New button to put the formview in insert mode
(using FormView1.ChangeMode(FormViewMode.Insert) i see on the screen the
input controls as normal, but when i loop thru the page controls as before it
only contains the label counterparts.

if i put a FormView1.DataBind() after the
FormView1.ChangeMode(FormViewMode.Insert) i can then see the proper input
controls.

what does DataBind really do behind the scenes? (i learn better with simple
analogies please)

thanks,
rodchar
Jul 10 '08 #1
3 1488
Hi

Its simple ... databind set a bond between your ui and data...

http://weblogs.asp.net/leftslipper/a...tatements.aspx
Best of luck

-----------
Munna

www.munna.shatkotha.com/blog
www.munna.shatkotha.com
www.shatkotha.com
Jul 10 '08 #2
so what is the alternative to databinding?

"Munna" wrote:
Hi

Its simple ... databind set a bond between your ui and data...

http://weblogs.asp.net/leftslipper/a...tatements.aspx
Best of luck

-----------
Munna

www.munna.shatkotha.com/blog
www.munna.shatkotha.com
www.shatkotha.com
Jul 10 '08 #3
Managing the process by hand, assigning values from a data store to the
controls when the page or control loads and doing updates etc. when values
are changed and the page is submitted.

--

Joe Fawcett (MVP - XML)
http://joe.fawcett.name

"rodchar" <ro*****@discussions.microsoft.comwrote in message
news:7B**********************************@microsof t.com...
so what is the alternative to databinding?

"Munna" wrote:
>Hi

Its simple ... databind set a bond between your ui and data...

http://weblogs.asp.net/leftslipper/a...tatements.aspx
Best of luck

-----------
Munna

www.munna.shatkotha.com/blog
www.munna.shatkotha.com
www.shatkotha.com
Jul 12 '08 #4

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

Similar topics

9
3304
by: Mike L | last post by:
I tried a sample of code in MSDN magazine, but now I'm stuck. What code has the best performance to populate a Data Grid with a SP? Below is the code I have, which might be completing the wrong...
6
4468
by: Mark | last post by:
I have been working for quite some time on this issue which in theory should be quite simple. The problem is that the Cancel and Save events are not fired when their respective buttons are...
5
2832
by: Joel Reinford | last post by:
I am attempting to verify whether a datareader is closed by calling the databind on a control. for example (fake code) Dim rdr as SqlDataReader rdr = mycommand.executeReader... ...
1
6776
by: Luis Esteban Valencia | last post by:
Compilation Error Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source...
1
1278
by: Arjen | last post by:
Hi, I'm using the repeater with the objectdatasource. The repeater databinds without adding "Repeater1.DataBind();" in code behind. If I add "Repeater1.DataBind();" inside code behind, does...
7
1911
by: ÀÏÆÅ»³ÔÐ5¸öÔ | last post by:
I want use dropdownlist contral in gridview but have trouble now mycode here: i'm very sorry for my poor english <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs"...
3
10330
by: K B | last post by:
Hi again, I've narrowed down my problem and am hoping to get some help to get the final answer. Gridview with dynamic child controls loads gv1.Databind calls RowDataBound event fine On the...
2
9937
by: sree reddy | last post by:
..cs using System; using System.Data; using System.Configuration; using System.Collections; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.WebControls;
6
1852
by: Jonathan Wood | last post by:
I have a databound dropdownlist control. Based on some other criteria, I need to specify the selected item in my pages Load event. The problem is that, in my load event, the control does not yet...
0
7203
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7282
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7463
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...
0
5581
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,...
0
4678
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...
0
3157
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1515
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 ...
1
738
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
389
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.