Detailsview adding first record

Discussion in 'ASP .Net' started by =?Utf-8?B?VGRhclRkYXI=?=, Sep 11, 2005.

  1. HI,
    I have a asp 2.0 page that has a sqldatasource and a detailsview i have
    enabled the inserting updating deleting in the datasoure. I have a blank
    table that has no records. I run the page.. I get a blank page how can I
    toggle the detailsview to show the new insert form if it has no records
    returned? So I can insert the very first record into the system.
     
    =?Utf-8?B?VGRhclRkYXI=?=, Sep 11, 2005
    #1
    1. Advertising

  2. Ok.... since there has been no comment makes me wonder if i did not give
    enough info.. And I am wondering to myself is this becase there is no
    autonumbered ID field in the table, I wanted to make my own id and not a auto
    generated one, but thinking I should but in a second key and maybe this will
    get solved? If you need to see what i am talking about created a new table
    with no record and only a key that is not an autonumber then start a web
    project in vs 2005 beta 2 and a new asp.net page then add a sqldatasourse to
    that table with insert add delete on and insert a detailsview control into
    that and link it to the datasoure and run the page..
    its blank no fields no way to select new for new record etc...

    Please Help!

    "TdarTdar" wrote:

    > HI,
    > I have a asp 2.0 page that has a sqldatasource and a detailsview i have
    > enabled the inserting updating deleting in the datasoure. I have a blank
    > table that has no records. I run the page.. I get a blank page how can I
    > toggle the detailsview to show the new insert form if it has no records
    > returned? So I can insert the very first record into the system.
    >
    >
     
    =?Utf-8?B?VGRhclRkYXI=?=, Sep 12, 2005
    #2
    1. Advertising

  3. Found it its the Default View property.

    "TdarTdar" wrote:

    > Ok.... since there has been no comment makes me wonder if i did not give
    > enough info.. And I am wondering to myself is this becase there is no
    > autonumbered ID field in the table, I wanted to make my own id and not a auto
    > generated one, but thinking I should but in a second key and maybe this will
    > get solved? If you need to see what i am talking about created a new table
    > with no record and only a key that is not an autonumber then start a web
    > project in vs 2005 beta 2 and a new asp.net page then add a sqldatasourse to
    > that table with insert add delete on and insert a detailsview control into
    > that and link it to the datasoure and run the page..
    > its blank no fields no way to select new for new record etc...
    >
    > Please Help!
    >
    > "TdarTdar" wrote:
    >
    > > HI,
    > > I have a asp 2.0 page that has a sqldatasource and a detailsview i have
    > > enabled the inserting updating deleting in the datasoure. I have a blank
    > > table that has no records. I run the page.. I get a blank page how can I
    > > toggle the detailsview to show the new insert form if it has no records
    > > returned? So I can insert the very first record into the system.
    > >
    > >
     
    =?Utf-8?B?VGRhclRkYXI=?=, Sep 12, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Guest
    Replies:
    7
    Views:
    691
    Walter Wang [MSFT]
    Jun 28, 2006
  2. JonBosker
    Replies:
    1
    Views:
    474
    Alexey Smirnov
    Feb 1, 2007
  3. Frits van Soldt

    How to insert a new record in detailsview when there are no record

    Frits van Soldt, Nov 16, 2005, in forum: ASP .Net Web Controls
    Replies:
    2
    Views:
    810
    Frits van Soldt
    Nov 17, 2005
  4. Feege
    Replies:
    0
    Views:
    493
    Feege
    Dec 20, 2005
  5. Maximus
    Replies:
    2
    Views:
    200
    Bob Barrows [MVP]
    Apr 12, 2007
Loading...

Share This Page