CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 Dynamic Hidden to textbox field

Print topic Send  topic

Author Message
Damian Small
Posted: 08/04/2002, 8:46 AM

Does anyone know if it would be posible to change a Hidden field to input textbox dynamically? I have a dropdown list and want the option of "Other" textbox input to appear if option Other is selected in the dropdown list. I would use the onchange event I dont want to create two forms on the page it would generate too much code. I need to show/hide the fields label as well.
ASP Templates CC2.05

Regards Damian
Nicole
Posted: 08/05/2002, 8:04 AM

Damian,
1. to display different controls depending on any condition, add Label type field to the form, select HTML flag in its properties and create form Before Show event like:
if condition then
fldfield1 = "<input type=""text"" name=""quantity"" maxlength=""10"" value="& fldfield1 &" size=""10"">"
or
fldfield1 = "<input type=""hidden"" name=""field1"" value="& fldfield1 &">"
end if

2. if you mean depending listboxes please refer to the article: http://www.gotocode.com/art.asp?art_id=45&

3. the simplest way is to assign empty value to the Label field. On what form do you want to hide fields?
Damian
Posted: 08/05/2002, 4:24 PM

Thanks Nicole
Number 1. did the trick. Inconjuction with an onChange event and a page refresh.

Regards Damian

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.