473,320 Members | 1,991 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Getting values from dynamically created control.

Jen
Hi

I have created some controls (HtmlInputText, HtmlGenericControl, TextBox) dynamically. But I have problem getting the values from these controls to save them. Is there a way to do that?

Regards and Many thanks
Jen
Nov 18 '05 #1
3 1942
A suggestion, which may not be the best way, is to write the values to DB
from the client side.

--------------------------------------------------------------------
This reply is provided AS IS, without warranty (express or implied).
--------------------
Thread-Topic: Getting values from dynamically created control.
thread-index: AcQoOasVlN8Cs8zqRKuFkUJeYvqmQQ==
X-WN-Post: microsoft.public.dotnet.framework.aspnet
From: =?Utf-8?B?SmVu?= <fr********@hotmail.com>
Subject: Getting values from dynamically created control.
Date: Thu, 22 Apr 2004 00:16:02 -0700
Lines: 8
Message-ID: <61**********************************@microsoft.co m>
MIME-Version: 1.0
Content-Type: text/plain;
charset="Utf-8"
Content-Transfer-Encoding: 7bit
X-Newsreader: Microsoft CDO for Windows 2000
Content-Class: urn:content-classes:message
Importance: normal
Priority: normal
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
Newsgroups: microsoft.public.dotnet.framework.aspnet
Path: cpmsftngxa10.phx.gbl
Xref: cpmsftngxa10.phx.gbl microsoft.public.dotnet.framework.aspnet:228195
NNTP-Posting-Host: tk2msftcmty1.phx.gbl 10.40.1.180
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

Hi
I have created some controls (HtmlInputText, HtmlGenericControl, TextBox)
dynamically. But I have problem getting the values from these controls to
save them. Is there a way to do that?

Regards and Many thanks,
Jen



Nov 18 '05 #2
> I have created some controls (HtmlInputText, HtmlGenericControl, TextBox)
dynamically. But I have problem getting the values from these controls to
save them. Is there a way to do that?


Jen, are you certain you are recreating these controls on every postback
to the page? If so, you should be able to programmatically reference
them after they have been created and read their property values.

--

Scott Mitchell
mi******@4guysfromrolla.com
http://www.4GuysFromRolla.com
http://www.ASPFAQs.com
http://www.ASPMessageboard.com

* When you think ASP, think 4GuysFromRolla.com!
Nov 18 '05 #3
Jen
Hi Scott,

I manage to get the values and save them successfully after recreating the controls on every postback. Thanks.

But it seems that this has slow my saving process. I need about 1min to save any changes in that form. Do you know of any way, I can resolve this. I currently have to dynamically create 250 columns on each postback.

Thanks.
Nov 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Joel Reinford | last post by:
I am working on an ASP.NET web app. One of the pages will be using several user controls. The controls will be loaded dynamically based on SQL Server data. I need to be able to retrieve the...
3
by: Varad | last post by:
Hi all Pls give me some insight as to what I should be doing. I have a form where I have 20 text boxes and when an user submits the form I save it to a database. When they want to retrieve it, I...
2
by: Colin McGuigan | last post by:
This is a translation of an ASP page to ASP.Net. First, the background: The goal is to have a grid of different settings for the application -- think something along the lines of the Property...
2
by: R Duke | last post by:
I have tried everything I can think of to change the visible property of a design time created control from a dynamically created control's command event handler. Here is the scenario. I have...
9
by: james.e.coleman | last post by:
Hello, I have created a custom dropdownlist that is used multiple times within a single page. When trying to set the values of the controls with the page in which they are being used, they all...
4
by: Larry Grady | last post by:
Anyone up for a challenge? I've been struggling with this for a few days and was hoping someone could help me. Pouring through all the messageboards I just can't find the solution. We have a...
0
by: reddog | last post by:
Getting the SelectedIndex of a DropDownlist under the ItemTemplate in a GridView is harder than I thought it would be. I have: A Gridview of n rows bound to a DataSet. A DropDownList as an...
12
by: vbnewbie | last post by:
I am having problems accessing properties of dynamically generated objects in VB2005. Can someone please help? In a nutshell: My app creates an equal number of checkboxes and labels that share the...
2
by: RSH | last post by:
Hi, I have a CheckBoxList that is dynamically created in the codebehind. When I click the submit button on the form I am handling the click event but I cant get at the checked values of the...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.