473,834 Members | 1,873 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Mutiple submit buttons in a single page

Hi,

I pretty sure I've seen this problem addressed before, but I can't find any
references.

The short story is that I have I have multiple submit buttons on a page,
each providing different functionality. For example, I have a search option,
a log in option and a save text option.

I would like to handle the submits in the Click event of each button. the
problem is, that since only one form is allowed per page, only the first
button's Click event fires.

I've tried capturing keypresses with client-side code in an attempt to force
the user to click the corresponding button for each set of functionality,
but have found that to be very unreliable across browsers.

Are there any resources available that address this problem?

Thanks,
Bob Lehmann

Nov 22 '05 #1
4 1959
To clarify - I'm trying to handle the Click when the ente key is pressed.

Bob Lehmann

"Bob Lehmann" <no****@dontbot herme.zzz> wrote in message
news:uS******** ******@TK2MSFTN GP10.phx.gbl...
Hi,

I pretty sure I've seen this problem addressed before, but I can't find any references.

The short story is that I have I have multiple submit buttons on a page,
each providing different functionality. For example, I have a search option, a log in option and a save text option.

I would like to handle the submits in the Click event of each button. the
problem is, that since only one form is allowed per page, only the first
button's Click event fires.

I've tried capturing keypresses with client-side code in an attempt to force the user to click the corresponding button for each set of functionality,
but have found that to be very unreliable across browsers.

Are there any resources available that address this problem?

Thanks,
Bob Lehmann

Nov 22 '05 #2
Are you talking about ASP.NET? if yes, are the submit buttons you mentioned
WebCobtrol buttons? If your answer is yes, then all these buttons have
server side Click event that you can handle. I do not understand why you
call this a problem, unless these buttons are all HTML buttons and not run
at server (i.e without "runat='sev er'" attribute). But since you are asking
in .NET group,...

"Bob Lehmann" <no****@dontbot herme.zzz> wrote in message
news:uS******** ******@TK2MSFTN GP10.phx.gbl...
Hi,

I pretty sure I've seen this problem addressed before, but I can't find any references.

The short story is that I have I have multiple submit buttons on a page,
each providing different functionality. For example, I have a search option, a log in option and a save text option.

I would like to handle the submits in the Click event of each button. the
problem is, that since only one form is allowed per page, only the first
button's Click event fires.

I've tried capturing keypresses with client-side code in an attempt to force the user to click the corresponding button for each set of functionality,
but have found that to be very unreliable across browsers.

Are there any resources available that address this problem?

Thanks,
Bob Lehmann

Nov 22 '05 #3
> Are you talking about ASP.NET?
Yes.
are the submit buttons you mentioned WebCobtrol buttons? Yes.
then all these buttons have server side Click event that you can handle. I know.
I do not understand why you call this a problem As I said, because you are only allowed one form on a page only the first
button's Click event fires when a user presses Enter.

Bob Lehmann

"Norman Yuan" <No***@NoExist. No> wrote in message
news:TLURd.2298 1$AO.1677@clgrp s12... Are you talking about ASP.NET? if yes, are the submit buttons you mentioned WebCobtrol buttons? If your answer is yes, then all these buttons have
server side Click event that you can handle. I do not understand why you
call this a problem, unless these buttons are all HTML buttons and not run
at server (i.e without "runat='sev er'" attribute). But since you are asking in .NET group,...

"Bob Lehmann" <no****@dontbot herme.zzz> wrote in message
news:uS******** ******@TK2MSFTN GP10.phx.gbl...
Hi,

I pretty sure I've seen this problem addressed before, but I can't find

any
references.

The short story is that I have I have multiple submit buttons on a page,
each providing different functionality. For example, I have a search

option,
a log in option and a save text option.

I would like to handle the submits in the Click event of each button. the problem is, that since only one form is allowed per page, only the first
button's Click event fires.

I've tried capturing keypresses with client-side code in an attempt to

force
the user to click the corresponding button for each set of functionality, but have found that to be very unreliable across browsers.

Are there any resources available that address this problem?

Thanks,
Bob Lehmann


Nov 22 '05 #4
Bob,

Than you should probably set the focus on the next. I could not do that
using serverside code yet, because it has to be done as the button is placed
in HTML on the page by the browser.
This is a textbox, however a button would be the same in my opinion.

<INPUT tabindex="1" id="TextBox1" type="text" size="27">

//This should be the last rows in your html aspx file

<script language="JavaS cript">
document.all("f ieldid").focus( );
</script>
</HTML>

I hope this helps a little bit?

Cor
Nov 22 '05 #5

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

Similar topics

4
422
by: Bob Lehmann | last post by:
Hi, I pretty sure I've seen this problem addressed before, but I can't find any references. The short story is that I have I have multiple submit buttons on a page, each providing different functionality. For example, I have a search option, a log in option and a save text option. I would like to handle the submits in the Click event of each button. the
6
3109
by: CJM | last post by:
Can somebody clarify if/how/when a simple form is submitted when the <Enter> key is pressed? As I understood it, if you have a form with a single submit button, if enter is pressed, the form should be submitted as if the button is pressed. Is this correct? Does this behaviour vary across browsers? Chris
0
1470
by: deepak | last post by:
i have set multiple selection property in bith listboxes(html control) to true. i have taken 2 buttons(html control) say Button1,Button2.now i want to add mutiple selected items to another listbox after clicking button1, and similray remvoing the mutiple selected ite,s from, another after clicking button2 ,, how can i do this ,, my script is given belo...
5
20019
by: Alex Maghen | last post by:
In ASPX 2.0 with MasterPages and all that, my entire page only has one actual <FORM>. But there are several different sections of the page that provide what are functionally separate forms with separate Submit buttons. In basic HTML, I can have multiple forms on a page and the browser knows that if any of the fields for Form A have the focus, then pressing ENTER will send a Click to the submit button for Form A. Same for Form B, etc. ...
10
1964
by: underground | last post by:
I need a little help figuring this one out. I have a script that I've modified to post mutiple binary files into a single row but instead of copying the indiviuals files it rewrites the first file to all the other columns in the row... Could someone help me with this . Below is the complete script...and form.. <?php if(isset($_POST) && $_FILES && $_FILES && $_FILES && $_FILES && $_FILES && $_FILES && $_FILES > 0) { $fileName = $_FILES;...
7
2092
by: Bjorn Sagbakken | last post by:
Hello. There maybe an simple answer to this, but sometimes one get a strange blindness when working intensely on one single problem. I'm using ASP.NET 2003, building pages that include 3 user controls (banner, top-menu and sub-menu). The top-menu contains like five asp:buttons. Further down the form there is search field with another asp:button. And I naturally want this button to act as submit button in the sense that when
5
1943
by: Alex | last post by:
Hello, I hope I can explain this properly. I'm writing an application with a tabbed-based navigation, and a form which gets filled out by users will be split into 5 subtabs. What I need is instead of the user needing to hit a SUBMIT button each time the form within a tab is complete (Before clicking the next tab), I want clicking any tab to submit the data. I'm affraid that by not doing this, people will fill out the data in tab 1,...
7
1952
by: Petr Vileta \(fidokomik\) | last post by:
I have a form with few text inputs. Every text input is followed by image type input. In this form I want to have 1 submit button on the top. A problem I want to resolve is: when user type something into text input and press enter then I want to submit form by image type button but not by submit button. I tried to use tabindex parameter but this not work as I expect. Any idea? Code example:...
3
6318
by: xtremebass | last post by:
Hi Bytes. i have 3 submit buttons namely click1,click2 and click3 . if i press the any of one submit button page submitted appropriate page correctly, But the problem is display the all submit buttons in single line but it displays line by line (one line after another button displayed) . code i used is :
1
4889
by: chennaibala | last post by:
can any one send me mutiple image upload program and save the file name with extension in mysql table.we must cheak uploaded file type like bmp or any image file while uploading. i develop program,which can upload many file in folder.problem is,am unable to save my file name in to database.because i used same name for all input file type as file. i dont know get name of file.below i presented my coding for ur view.fed up with my coding..pls...
0
10510
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10548
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10219
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9331
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7758
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5627
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5794
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3978
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3081
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.