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

Home Posts Topics Members FAQ

Where is bound data stored?

Hi,

I am trying to find out where a bound dataset is being stored. I am
fairly new to all this so let me try to explain with an example using
my code:

if( !IsPostBack)
{
grdMyDataGrid.D ataSource = GetData();
grdMyDataGrid.D ataBind();
}

Since my data persists every time I do a postback, it must be stored
somewhere. Is it stored in my ViewState? In the Session? Some other
mechanism?

Thanks in advance.

Oct 17 '06 #1
3 1143
Hi,

the DataSet itself isn't stored as is, but your grid control is able to
store relevant data in ViewState so that it can reconstruct itself on
postback. E.g the data it gets when databinding.

--
Teemu Keiski
ASP.NET MVP, AspInsider
Finland, EU
http://blogs.aspadvice.com/joteke
<rb********@arm brotransport.co mwrote in message
news:11******** *************@e 3g2000cwe.googl egroups.com...
Hi,

I am trying to find out where a bound dataset is being stored. I am
fairly new to all this so let me try to explain with an example using
my code:

if( !IsPostBack)
{
grdMyDataGrid.D ataSource = GetData();
grdMyDataGrid.D ataBind();
}

Since my data persists every time I do a postback, it must be stored
somewhere. Is it stored in my ViewState? In the Session? Some other
mechanism?

Thanks in advance.

Oct 17 '06 #2
I know this isn't an answer, but I have got a problem I think is related to
this question. I've got data in a tbl in sql that gets deleted and
repopulated constantly, when I populate this data into a gridview and I
refresh the page, the gridview keeps adding the data sequentially instead of
displaying the actual data in the table...this is with SQL 2000 and ASP.NET
on .NET 2.0

--
The walls between art and engineering exist only in our minds
"Teemu Keiski" wrote:
Hi,

the DataSet itself isn't stored as is, but your grid control is able to
store relevant data in ViewState so that it can reconstruct itself on
postback. E.g the data it gets when databinding.

--
Teemu Keiski
ASP.NET MVP, AspInsider
Finland, EU
http://blogs.aspadvice.com/joteke
<rb********@arm brotransport.co mwrote in message
news:11******** *************@e 3g2000cwe.googl egroups.com...
Hi,

I am trying to find out where a bound dataset is being stored. I am
fairly new to all this so let me try to explain with an example using
my code:

if( !IsPostBack)
{
grdMyDataGrid.D ataSource = GetData();
grdMyDataGrid.D ataBind();
}

Since my data persists every time I do a postback, it must be stored
somewhere. Is it stored in my ViewState? In the Session? Some other
mechanism?

Thanks in advance.


Oct 17 '06 #3
The data is stored in viewstate, which, by the way, can cause your web
pages to become outrageously bloated when used with a grid.

After rendering your page, select 'view source' from the browser.
Search for the hidden text field called "_VIEWSTATE ". All that encoded
data after the = sign is your grid data being persisted between
postbacks. When you submit your form, all that data goes back to the
server from the client so that asp.net can rebuild your grid. It makes
life simple at first for a developer and seems really cool at first...
but after a while, you realize that this is just "wrong" and you'll
figure out ways to get your grid to continue working even after setting
"enableviewstat e=false". If you begin to have performance problems,
this is one of the first places to look.

Oct 18 '06 #4

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

Similar topics

1
302
by: Skip Borland | last post by:
I understand that in .Net, there is no such animal as the "bound OLE" frame available in Access. Unfortunately, as we migrate off of an old (97 - yikes!) application, combine it with functionality from an old (VS390 - double yikes) mainframe based processing system into our brand spankin' new Winforms C# app, this embedded and bound OLE is something I'd really like to replicate. We store word docs as OLE objects in MS SQL server, retrieve...
10
6976
by: serge | last post by:
I am doing a little research on Google about this topic and I ran into this thread: http://groups.google.com/group/microsoft.public.sqlserver.programming/browse_thread/thread/63cce060ff152dcc/1dc13d4ee6758966?lnk=st&q=difference+constraint+sql+defaults&rnum=14#1dc13d4ee6758966 I read SQL Server MVP Louis Davidson's post saying: "Actually they are more likely to drop the concept of bound defaults. Constraints are the standard way to do...
19
4118
by: James Fortune | last post by:
I have a lot of respect for David Fenton and Allen Browne, but I don't understand why people who know how to write code to completely replace a front end do not write something that will automate the code that implements managing unbound controls on forms given the superior performance of unbound controls in a client/server environment. I can easily understand a newbie using bound controls or someone with a tight deadline. I guess I need...
4
4623
by: jon f kaminsky | last post by:
Hi- I've seen this problem discussed a jillion times but I cannot seem to implement any advice that makes it work. I am porting a large project from VB6 to .NET. The issue is using the combo box bound to a table as a lookup, drawing values from another table to populate the available selections. This all worked fine in VB6. I have distilled the problem down to a simple form drawing data from the Northwind database for a representative...
57
3835
by: TC | last post by:
I'd like to open a discussion about the state of the industry. For the past year, I've been unable to find competent Access developers available for hire. I'm worried about that. I think there's great demand right now, and that's keeping the good developers busy, but that's not enough to explain the situation. Whenever I post an Access job, I get lots of responses from .NET developers, back-end database people, and web developers. They...
8
3307
by: Jon Weston | last post by:
I'm setting up an Access2003 database with pictures. I put a bound ole picture ctrl on a form that's source is the table that contains the pictures and follow ALL the directions for embedding a picture. The ctrl in the form only displays the filename of the picture. The underlying table, when opened in table view, shows the word "package" in the field. When I double-click on either it opens the picture, but I can't get it to display. ...
2
2148
by: Anonieko | last post by:
Hello ASPNET guru's, What is a clean way to go around the problem of displaying a GridView templated column where data can contain Single Quote ( ' )? I maybe too naive, but this is of course a common scenario. Scenario: * My database returns names that can contain single quote.
5
1233
by: drdave | last post by:
Hi, In a bound column I have currency datatypes, but the client does not like $ 0.00 and wants to show a blank instead.. I'm trying to use an if statement to write out string.empty but it doesn't want to allow the different datatype.. The currency amounts are stored as number in the db... How can I accomplish this?
43
5217
by: Kislay | last post by:
Which of the following is correct regarding the storage of global variables : 1. Global variables exist in a memory area that exists from before the first reference in a program until after the last reference . 2.Global variables exist in the initialized data segment .
0
9605
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10651
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10393
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
10405
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
10136
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
9208
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
7671
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...
2
3871
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3020
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 can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.