Best way to populate a form with a DataList link?

From: Mal P (pandorastein_at_hotmail.com)
Date: 06/22/04


Date: 21 Jun 2004 23:54:59 -0700

Hi there,

I'm a J2EE fellow who (as usual) has been thrown in the deep end and
have to learn a fair chunk of the .NET platform (VS, ADO, WebForms, C#
etc) in roughly two days. I'm doing ok so far, but am wondering on a
better way to do something...

Basically, I have a form which has a few fields the user fills in.
When submitted, the data is stored as a row in an SQL database table.
Then, I have another page which lists all the rows from that database
in tabular format. I use a DataList to do the displaying.

What I want to do is to have an "Edit" link next to each row which
will then go back to my original form, with all the fields populated
with the current values. The user can modify them, and re-submit.

I fiddled with the EditTemplate for the DataList but that's not what I
wanted - it seems to allow editing directly on my viewing only page. I
want the user to be re-directed to the separate form page. In the end,
due to a lack of time, I basically called the page with a get query
(i.e. formpage.aspx?report_id=45) and used the queryString to get the
report_id unique value of the record I wanted the fields in my form
populated with.

Anyone have a better suggestion on how to do this?

Thanks everyone,
Mal



Relevant Pages

  • Re: Incorrect code page conversion
    ... > I am seeing an incorrect conversion of data stored in SQL database with ... > We are using ADO, but I suspect this is an OLE DB issue. ... What is the ANSI code page on the various boxes? ...
    (microsoft.public.data.oledb)
  • Re: Please Help!How to write/read 7.5 K binary data to SQL database
    ... Essentially it is a binary type but allows ... to keep values bigger tan 8000 bytes. ... > Visual C++ 6.0, SQL Database, ADO. ...
    (microsoft.public.data.ado)
  • ADO ODBC CONNECTION STRING
    ... I have an access data base with linked tables from an Ms sql database. ... I am trying to use ADO in VBA to list the odbc connection string for each linked table. ... I have some code using DAO that can do this using the "connect" property of a tabledef object. ...
    (microsoft.public.data.ado)
  • Re: Write to a file
    ... >I want to read dada from SQL database and write it to a ... > ASCII comma delimited file. ... Convert an ADO Recordset to Text ... Convert Database Data Between Serveral Formats Using ADO ...
    (microsoft.public.vb.general.discussion)