David, left click on the left-side column of VS.Net, a red dot should
appear...that's a breakpoint...Alternatively, you can put your cursor on a
line, goto "Debug" --> "New Breakpoint". Now, hit f5 or "Debug" -->
"Start" which should build and start up your application, launching
IE...now you can browse your site as always, but when the code execution
hits any line with a breakpoint, it'll stop at that line...you can use f10
and f11to step over/in functions/lines....you can add "watches" to
values...play with it...you won't regret it...
You either have to reload the dataset, or store it in the Cache or Session
or some place...
Karl
--
MY ASP.Net tutorials
http://www.openmymind.net/ - New and Improved (yes, the popup is
annoying)
http://www.openmymind.net/faq.aspx - unofficial newsgroup FAQ (more to
come!)
"david" <(E-Mail Removed)> wrote in message
news:33F85FAE-AADC-4A34-BDAA-(E-Mail Removed)...
> Thank you very much.
> How to store the dataset as for a postback?
> I have .NET 2003. But I never use the debugging tool.
>
> David
>
> "Karl Seguin" wrote:
>
> > ds wont' automatically survive a postback....are you repopulating it on
> > postback? Storing it somewhere?
> >
> > If you have vs.net 2003, debug and step through the code...see what is
> > null...no point in trying to solve all 3 potential problems until we
know
> > which it is..
> >
> > Karl
> >
> > --
> > MY ASP.Net tutorials
> > http://www.openmymind.net/ - New and Improved (yes, the popup is
> > annoying)
> > http://www.openmymind.net/faq.aspx - unofficial newsgroup FAQ (more to
> > come!)
> > "david" <(E-Mail Removed)> wrote in message
> > news:B6C92D9B-5EA4-40AF-86E1-(E-Mail Removed)...
> > > ds is a DataSet.
> > > ds.Tables(0) should be ds.Tables("Patients")
> > > "LastName" is the colunm name.
> > > When Page is first loaded, it OK.
> > > That ocurs when I select a new item of dropdown list.
> > > It is supporsed to bind a new set of data display in all other
textbox.
> > > Does it mean the dataset ds has disappeared?
> > >
> > > Thanks
> > >
> > > David
> > >
> > >
> > >
> > > "Karl Seguin" wrote:
> > >
> > > > txtLastName is null, ds is null or there's no table named
> > "Patients"....we
> > > > can't tell which it is, but one of those is true...
> > > >
> > > > Karl
> > > >
> > > > --
> > > > MY ASP.Net tutorials
> > > > http://www.openmymind.net/ - New and Improved (yes, the popup is
> > > > annoying)
> > > > http://www.openmymind.net/faq.aspx - unofficial newsgroup FAQ (more
to
> > > > come!)
> > > > "david" <(E-Mail Removed)> wrote in message
> > > > news:97AF5BFC-0148-481F-B4B0-(E-Mail Removed)...
> > > > > I have a question in the following. Any one could give me a help?
> > > > > Thanks
> > > > > David
> > > > >
> > > > > The dataset is declared and created at Class level. My source code
is
> > > > here:
> > > > >
> > > > > Private Sub lstPatientID_SelectedIndexChanged(ByVal sender As
> > > > System.Object,
> > > > > ByVal e As System.EventArgs) Handles
lstPatientID.SelectedIndexChanged
> > > > > txtDebug.Text &= lstPatientID.SelectedIndex.ToString
> > > > > txtDebug.Text &= lstPatientID.SelectedIndex.ToString
> > > > > txtLastName.Text =
> > > > > ds.Tables("Patients").Rows(lstPatientID.SelectedIndex)("LastName")
> > > > >
> > > > > When Page_load,
> > > > > I use Dropdown list index to set all textboses. Now select another
> > item in
> > > > > Dropdown list, I got the following error at Line 323:
> > > > >
> > > > > Exception Details: System.NullReferenceException: Object reference
not
> > set
> > > > > to an instance of an object.
> > > > >
> > > > > Source Error:
> > > > > Line 321: txtDebug.Text &=
lstPatientID.SelectedIndex.ToString
> > > > > Line 322: txtDebug.Text &=
lstPatientID.SelectedIndex.ToString
> > > > > Line 323: txtLastName.Text =
> > > > > ds.Tables("Patients").Rows(lstPatientID.SelectedIndex)("LastName")
> > > > >
> > > > > Line: 323
> > > > >
> > > > >
> > > >
> > > >
> > > >
> >
> >
> >