View Single Post
  #1 (permalink)  
Old 08-16-2007, 03:52 PM
TeraTask's Avatar
TeraTask TeraTask is offline
PT Admin
Awards Showcase
Quality Tutorial Quality Tutorial Quality Tutorial 
Total Awards: 3
Join Date: Jun 2007
Location: Reno, NV
Posts: 440
iTrader: (0)
TeraTask is a splendid one to beholdTeraTask is a splendid one to beholdTeraTask is a splendid one to beholdTeraTask is a splendid one to beholdTeraTask is a splendid one to beholdTeraTask is a splendid one to behold
[SOLVED] DataSets, DataTables, and trying to save data

Well, I'm in way, way, way over my head with C#. I'm creating an app for a client which reads logins into a site, reads a webpage, extracts data from it, downloads PDFs from the site according to the extracted data, allows the user to view the PDFs, saves the extracted data and some user-entered data into a file, and fetches some more information after that. Phew! I've been going along quite well for the last week and even have the PDFs being downloaded via multithreading (thanks to copy-and-paste-and-tweak code), but I'm stuck on trying to save the data. I have figured out how to create a DataSet and add a DataTable. I can then add an interface to that table with the ability to add, edit, and delete rows. I can loop through the data and do whatever I want with it, but I can't seem to get it to save the data so that I can load it back in. Here's the details:

1) A database is not allowed.
2) I've added a save button to the form which is supposed to save the data when clicked. Here's the body (where nodWorkingData is the table name):

Code:
            try
            {
                this.nodWorkingData.AcceptChanges();
            }
            catch (Exception ex)
            {
                MessageBox.Show("Error");
            }
3) I'm trying to load the data using the Load command, but it expects an IDataReader Interface and that's where I get totally lost. I can't even figure out where the data is saved from step 2.

Can anyone help me?


Thanks a billion in advance!

__________________
Jeremy Miller
Content Farmer - Optimized Automated Blog Posting

Digg this Post! Del.Icio.Us this Post! Technorati this Post! Furl this Post! Mister Wong this Post! Newsvine this Post! Spurl this Post! Reddit this Post! Netscape this Post!