Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 25th, 2006, 06:08 AM
Authorized User
 
Join Date: May 2006
Location: , , .
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Default Submit button not fired.

Hi all,

   I designed a form with adding table control and then dynamically add textbox controls. here is sample code snipnet.

My problem is when there are 2 textbox controls and enter something in that controls and press enter, submit button fired.

But if only one textbox control is present then if I enter submit button, then it was not fired.

Thanks in advance.

Ram.

Dim paraTable As System.Web.UI.WebControls.Table
Dim aRow As New TableRow
Dim aControlCell As New TableCell
Dim aLabelCell As New TableCell
Dim aValidatorCell As New TableCell
Dim atextbox As New System.Web.UI.WebControls.TextBox
atextbox.Width = System.Web.UI.WebControls.Unit.Point(100)
atextbox.ID = paramName
atextbox.Width = System.Web.UI.WebControls.Unit.Point(100)
atextbox.Visible = True
aControlCell.Controls.Add(atextbox)

Dim label As New System.Web.UI.WebControls.Label
label.Text = "Enter you name"

aLabelCell.Wrap = False
aLabelCell.VerticalAlign = VerticalAlign.Middle
aLabelCell.Controls.Add(label) 'add the label to the cell
aRow.Controls.Add(aLabelCell) 'add the label cell to row
aRow.Controls.Add(aControlCell) 'add the control cell to row
aRow.Controls.Add(aValidatorCell) 'add the validator cell to row
paraTable.Controls.Add(aRow) 'add the row to the table

ParamTable.Rows(0).Cells(0).Controls.Add(paraTable )



 
Old August 30th, 2006, 12:51 AM
Friend of Wrox
 
Join Date: Feb 2006
Location: , , USA.
Posts: 116
Thanks: 0
Thanked 0 Times in 0 Posts
Default

What kind of object is the ParamTable?

Where are your event handlers for the button click events?



Neil Timmerman
Programmer
Veris Consulting




Similar Threads
Thread Thread Starter Forum Replies Last Post
Make a image button as default submit button toshi ASP.NET 1.0 and 1.1 Basics 1 June 1st, 2006 05:25 AM
Submit Button trusslady Infopath 2 January 6th, 2006 05:19 PM
submit-button grstad Javascript How-To 1 May 25th, 2005 08:33 AM
Submit Button Night_Zero Classic ASP Databases 1 August 17th, 2004 04:55 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.