Data Sets

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I use the XP Pro OS and VB.NET in VS 2003 as my development platform. Over
the last year, I have been trying to compress my development into as few
files as possible. For instance, for similar report pages I have
consolidated into a single .aspx page and used dynamic datagrids
(programatically created and configured rather that in the designer) rather
than having multiple pages. Also, if I have a project with many .aspx pages
I will place all tables generated from data adapters into a single data set.

Recently however, one of my users pointed out a bug that I am having trouble
fixing. Some of my databound controls are not pulling the data properly. If
I regenerate the data set the problem is fixed. The weird part is that if I
do other work (on a different .aspx page!) and regenerate the data set for a
different table my recently fixed problem on the previous page reemerges.

I speculate that this may have something to do with the data set. My
rationale in dumping everything into a common data set has been that if I
call a page that reuses a table (albeit filtered with a different WHERE
clause) the fill method of the data set should take care of the pulling in
the right values. Is this wrong?

TIA,
Gil
 
I don't believe I am persisting data? I simply use the fill method to
populate my data set using:

private sub page_load(...)
if not page.ispostback then
...
daAdapter.fill(me.dsDataset)
...
end if

My thought was that if the data adapter is specified in the code behind then
it will simply use the definition, when the page is called, and populate the
data set with the right data.

Gil
 
Hi Gil,

I asked if you were persisting the DataSet or had enable page caching
because doing so could give you the issue you described.


--
Mike

Mike McIntyre
Visual Basic MVP
www.getdotnetcode.com
 
Back
Top