Results 1 to 2 of 2

Thread: Adding to Datasets

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jun 2000
    Location
    Ontario, Canada.
    Posts
    85

    Adding to Datasets

    I have a page that has a dataset is loaded on page load.
    The user can add records to the dataset, and will not be updated
    to the table the dataset was loaded from.

    Right now I have it set up so that every time the page is loaded the dataset is loaded. And the add new record is performed with an insert into.

    I want to change this so that I add to the dataset, and only update the table on submit. I can add a row to the dataset, but on the postback the row in the dataset is loss since the update to the table is not performed.

    Should I be saving the dataset as a session variable and loading it on postback???

    Thanks in advance.
    Jimmer

  2. #2
    Addicted Member rdove's Avatar
    Join Date
    Dec 2002
    Location
    Indianapolis
    Posts
    251
    I'm not positive is this is exactly what you are wanting, but here is what I would try:

    Code:
    If Not Page.IsPostBack Then
    
    'code
    
    End If
    ~Ryan





    Have I helped you? Please Rate my posts.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width