Re: Repeating section control in ASP.NET

From: Christoph (jcboget_at_yahoo.com)
Date: 07/18/04


Date: Sun, 18 Jul 2004 14:00:16 -0500


> Ok, no, ASP.NET doesn't do this. It's possible that you could do something
> like this with ASP.NET 2.0, though I think you'd still wind up creating
your
> own control. See the most recent issue of MSDN Magazine for a discussion
of
> the new GridView control and how it works with the new DataSource
controls.
> It seems to me that one could have a DataSource control which would allow
> you to add data client-side (perhaps as XML stored in a hidden field), but
> which would then actually insert the changes into the database once the
form
> posted back.

Ok So I guess I'm just going to have to do this the old fashioned way with
DHTML, which is fine as I've done it often enough in the past. But if I do
it this way, I'm still left with my second issue/question -- how do I access
these new, dynamically created HTML form elements in the back end code?
In PHP, this was easy as I could just iterate through the $_POST (or the
$_REQUEST) arrays and just grab all the keys that matched the base name
of the control. It doesn't seem as if ASP.NET has anything close to that
for me to use. As such, I'm not sure how I'd be able to access the values
of those controls.
Just wanted to make a quick comment that I'd rather not post back to the
server to create the new row of form elements and instead create them
dynamically via the client. If I post back to create the form, accessing
the
new form elements/controls is a no brainer.

Thanks again for your time and assistance!

Christoph



Relevant Pages

  • Re: Repeating section control in ASP.NET
    ... > the new GridView control and how it works with the new DataSource ... > It seems to me that one could have a DataSource control which would allow ... > you to add data client-side, ... dynamically created HTML form elements in the back end code? ...
    (microsoft.public.dotnet.framework.aspnet.webcontrols)
  • Re: [ENTER] key causing major headaches.
    ... As you can do in Legacy ASP, try client-side script to control the OnKeyPress ... event of the form elements you want to capture the ENTER key for and simulate a ... Doing this does not fire either Click event. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: UserControl From Module
    ... a module and a user control with all the form elements. ... The only multithreading VB Classic supports is through the use of ActiveX ...
    (microsoft.public.vb.controls)
  • Re: [PHP] Comparing string to array
    ... They can name the form elements with any valid name. ... Which when bought back into PHP will come out as: ... could nest the resulting array as deep in $_POST as they like. ... If you have no control over what the fields in the form will be, what are you doing with the data? ...
    (php.general)
  • RE: Finding a way to bind ASP.NET controls(two way) to a typed-dataset
    ... through the new ASP.NET 2.0 Databound control and DataSource control. ... ObjectDataSource, however, currently since the default datasource control ...
    (microsoft.public.dotnet.framework.aspnet.webcontrols)