473,513 Members | 2,658 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Default button setup

I have 3 objects on my page (textbox,button and linkbutton)

When I put something in my textbox and hit "enter", the page gets posted,
but nothing happens. I don't go to either of the functions that both
buttons are set up for.

If I push the buttons directly, it works fine.

The Button is the first button on the page and the one I want to be default.
Is there something I have to do to make it a default button?

Thanks,

Tom
Nov 19 '05 #1
4 1419
its a minor bug in IE. its supposed to post the first button, but fails in
this simple case (more controls it works better). google this newsgroup for
help on implementing a default button of your choice.

-- bruce (sqlwork.com)

"tshad" <ts**********@ftsolutions.com> wrote in message
news:%2****************@TK2MSFTNGP14.phx.gbl...
I have 3 objects on my page (textbox,button and linkbutton)

When I put something in my textbox and hit "enter", the page gets posted,
but nothing happens. I don't go to either of the functions that both
buttons are set up for.

If I push the buttons directly, it works fine.

The Button is the first button on the page and the one I want to be
default. Is there something I have to do to make it a default button?

Thanks,

Tom

Nov 19 '05 #2

"Bruce Barker" <br******************@safeco.com> wrote in message
news:uc**************@TK2MSFTNGP15.phx.gbl...
its a minor bug in IE. its supposed to post the first button, but fails in
this simple case (more controls it works better). google this newsgroup
for help on implementing a default button of your choice.
Found it.

If I put

Page.RegisterHiddenField("__EVENTTARGET", "btnSearch")

in the Page_Load event - it seems to work.

Thanks,

Tom
"tshad" <ts**********@ftsolutions.com> wrote in message
news:%2****************@TK2MSFTNGP14.phx.gbl...
I have 3 objects on my page (textbox,button and linkbutton)

When I put something in my textbox and hit "enter", the page gets posted,
but nothing happens. I don't go to either of the functions that both
buttons are set up for.

If I push the buttons directly, it works fine.

The Button is the first button on the page and the one I want to be
default. Is there something I have to do to make it a default button?

Thanks,

Tom


Nov 19 '05 #3
They have provided a work-around in ASP.NET 2.0 with the <form runat=server
defaultButton="SomeButton"> directive.

-Brock
DevelopMentor
http://staff.develop.com/ballen
I have 3 objects on my page (textbox,button and linkbutton)

When I put something in my textbox and hit "enter", the page gets
posted, but nothing happens. I don't go to either of the functions
that both buttons are set up for.

If I push the buttons directly, it works fine.

The Button is the first button on the page and the one I want to be
default. Is there something I have to do to make it a default button?

Thanks,

Tom


Nov 19 '05 #4
While waiting for v2 one can also utilize this free control

DefaultButtons
http://www.metabuilders.com/Tools/DefaultButtons.aspx

--
Teemu Keiski
ASP.NET MVP, AspInsider
Finland, EU

"Brock Allen" <ba****@NOSPAMdevelop.com> wrote in message
news:25**********************@msnews.microsoft.com ...
They have provided a work-around in ASP.NET 2.0 with the <form
runat=server defaultButton="SomeButton"> directive.

-Brock
DevelopMentor
http://staff.develop.com/ballen
I have 3 objects on my page (textbox,button and linkbutton)

When I put something in my textbox and hit "enter", the page gets
posted, but nothing happens. I don't go to either of the functions
that both buttons are set up for.

If I push the buttons directly, it works fine.

The Button is the first button on the page and the one I want to be
default. Is there something I have to do to make it a default button?

Thanks,

Tom


Nov 19 '05 #5

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

Similar topics

1
2632
by: Raphael Iloh | last post by:
Hi all, I have a Web Setup Project and would like to change the installation path from the default (i.e. C:\Inetpub\wwwroot\) to some more particular path (e.g. c:\myfolder\). Any ideas on this...
3
4078
by: David | last post by:
Hi, I have 3 buttons on a asp.net page. They are exactly the same except for the name. Two of the buttons works but the third one does not respond to the clicking. Here is the code: <tr> <td...
1
2775
by: gan | last post by:
I created a ASP.NET web setup project with the project name "Setup". I noticed that this name will be used as the default Virtual Directory name during deployment. I'd like to know whether we...
0
1056
by: Steve | last post by:
When the web site is not setup as the default then MapPath("virtname") returns the correct physical path for a virtual directory which has been setup. However, when the web site is setup as the...
1
12455
by: ImageAnalyst | last post by:
Yay!!! They fixed this for VS2005. You can now set the default installation to be "Everyone" instead of "Just Me" and you can control whether you even want those radio button installed in your...
3
2393
by: MLH | last post by:
Access 97 Q: Can I examine a report object property setting in VBA and tell whether the report is setup to print to a specific printer or to the windows default printer? You know, the setting...
0
1501
by: =?Utf-8?B?TWljaGVs?= | last post by:
Hello, When creating a setup project for my VB.NET application, the setup installs my program in c:\program files\default company name\Program name. I can rename then name of the map "Default...
6
9742
by: Ian | last post by:
I am trying to get MS Access 2000 to print names and addresses onto a Dymo 400 label printer, I have set the Access Report to automatically select the correct printer, then select the label size of...
8
3873
rrocket
by: rrocket | last post by:
I have a form that has various tables that are hidden. When the user selects a number from the DDL the corresponding number of tables shows up (using javascript). When the submit button is clicked...
0
7257
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7157
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7535
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...
1
7098
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...
1
5084
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...
0
3232
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...
0
3221
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1591
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
455
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...

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.