473,394 Members | 1,709 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,394 software developers and data experts.

Nothing happens when I click a button

I have added a Button control (also tried LinkButton with same result) and
some code to the click event to my web form in vb.net/vs.net.

When I test it from a browser (IE6) the button shows up but when I click it
nothing happens. In the IE status bar it says "javascript:{if
(typeof(Page_ClientValidate) != 'function' || Page_ClientValidate())
__doPostBack('btnTest','')}" but absolutely nothing happens when I click it.

There seems to be a couple of known bugs that are related to this, especially:
http://support.microsoft.com/?kbid=889877
and maybe this one:
http://support.microsoft.com/default...;en-us;q324735

I have tried running aspnet_regiis.exe -c but there is no difference.
I'm running .net framework 1.1 on a win2k3 server.

Any ideas are appreciated. Thanks.
Nov 19 '05 #1
14 3084
Hi,

is js enabled on your browser?

Daniel
"maxfloden" <ma*******@discussions.microsoft.com> schrieb im Newsbeitrag
news:43**********************************@microsof t.com...
I have added a Button control (also tried LinkButton with same result) and
some code to the click event to my web form in vb.net/vs.net.

When I test it from a browser (IE6) the button shows up but when I click
it
nothing happens. In the IE status bar it says "javascript:{if
(typeof(Page_ClientValidate) != 'function' || Page_ClientValidate())
__doPostBack('btnTest','')}" but absolutely nothing happens when I click
it.

There seems to be a couple of known bugs that are related to this,
especially:
http://support.microsoft.com/?kbid=889877
and maybe this one:
http://support.microsoft.com/default...;en-us;q324735

I have tried running aspnet_regiis.exe -c but there is no difference.
I'm running .net framework 1.1 on a win2k3 server.

Any ideas are appreciated. Thanks.

Nov 19 '05 #2
Yes it is. Besides I thought asp.net would check the browser and generate
proper code (ie not use javascript) if it wasn't?
Nov 19 '05 #3
ASP.NET does not work very well if you deactivate js. In fact, in HTML only
a few controls can perform a postback and therefor what ASP.NET does is that
it uses js to submit the page back to the server. As this is a limitation of
HTML ASP.NET has no chance to "generate proper code" if you disable js.
If you enable ja you'll see your button work.

HTHs

Daniel Walzenbach
"maxfloden" <ma*******@discussions.microsoft.com> schrieb im Newsbeitrag
news:F8**********************************@microsof t.com...
Yes it is. Besides I thought asp.net would check the browser and generate
proper code (ie not use javascript) if it wasn't?

Nov 19 '05 #4
ASP.NET *does* check the browser and, if you're using IE6,
*will* send JavaScript ( and not *not* send it, as you say ).

If you're using IE6, you *will* get JavaScript,
whether you've disabled it or not.


Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Español
Ven, y hablemos de ASP.NET...
======================

"maxfloden" <ma*******@discussions.microsoft.com> wrote in message
news:F8**********************************@microsof t.com...
Yes it is. Besides I thought asp.net would check the browser and generate
proper code (ie not use javascript) if it wasn't?

Nov 19 '05 #5
Ok. thanks for your reply. But as I said javascript IS enabled, so there has
to be something else.
Nov 19 '05 #6
Ok, I see, thanks. So it only checks what browser, not if it's capable of
running javascript.
Anyway this was just a sideline to my real problem. Any ideas why buttons
won't work for me (javascript is enabled in the browser)?
Nov 19 '05 #7
Sorry,

kind it was kind of late yesterday and my kapability of reading... Did you
try a simple asp.net page with *only one* button on it which only does
something like response.write("Hello World")? Do clicks in this example
work?

Daniel Walzenbach
"maxfloden" <ma*******@discussions.microsoft.com> schrieb im Newsbeitrag
news:79**********************************@microsof t.com...
Ok. thanks for your reply. But as I said javascript IS enabled, so there
has
to be something else.

Nov 19 '05 #8
I'd check to see whether your client
validation files are where they should be.

ASP.NET 1.1 :
drive:\Inetpub\wwwroot\aspnet_client\system_web\1_ 1_4322

You should have webuivalidation.js and smartnav.js there.

For more recent versions of the .Net Framework,
just replace your vesion number.

If the validation files aren't there, run aspnet_regiis -c
from a command window in your .Net Framework directory.

That will install them correctly.
Then, try your Page_ClientValidate button Javascript stuff again.


Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Español
Ven, y hablemos de ASP.NET...
======================

"maxfloden" <ma*******@discussions.microsoft.com> wrote in message
news:90**********************************@microsof t.com...
Ok, I see, thanks. So it only checks what browser, not if it's capable of
running javascript.
Anyway this was just a sideline to my real problem. Any ideas why buttons
won't work for me (javascript is enabled in the browser)?

Nov 19 '05 #9
I feel stupid for not aleady trying this but when I do as you suggest it DOES
WORK.
So this means there have to be something wrong with my page, any suggestions
how to troubleshoot?
Nov 19 '05 #10
Yes, they are there and I've already tried aspnet_regiis -c. However, as in
my reply to Daniel Walzenbach, I realize I haven't done much of
troubleshooting before posting here... It seems if I make a new really simple
page it works, so it has to be something on the specific page I'm trying it
on.
Thanks.

Nov 19 '05 #11
Is the the 'Handles' statement at the end of your button code subroutine?

private sub button_click(ByVal sender as System.Object, ByVal e As
Sytem.EventArgs) HANDLES BUTTON.CLICK

Galtac.

Nov 19 '05 #12
Yes, the "Handles" statement is there.

"galtac" wrote:
Is the the 'Handles' statement at the end of your button code subroutine?

private sub button_click(ByVal sender as System.Object, ByVal e As
Sytem.EventArgs) HANDLES BUTTON.CLICK

Galtac.

Nov 19 '05 #13
I had a similiar symptom except my pages were working on my dev machine
but wouldn't submit when I uploaded them. Uploading the .resx files
associated with the .aspx pages (which I hadn't been doing) fixed it.

The problem also went away when I got rid of the validation controls so
they must require the .resx files. I guess it makes sense that the
..resx files are needed since the pages get compiled on server but it
would have been nice to have an error message.

Anyway, hopefully that'll fix your problem too. Good luck!
*** Sent via Developersdex http://www.developersdex.com ***
Nov 19 '05 #14
Did you ever get an annswer. I'm having the same problem on a very old site i
did after a server crash.

please let me know

kes
--
thanks (as always)
some day i''m gona pay this forum back for all the help i''m getting
kes
"maxfloden" wrote:
I have added a Button control (also tried LinkButton with same result) and
some code to the click event to my web form in vb.net/vs.net.

When I test it from a browser (IE6) the button shows up but when I click it
nothing happens. In the IE status bar it says "javascript:{if
(typeof(Page_ClientValidate) != 'function' || Page_ClientValidate())
__doPostBack('btnTest','')}" but absolutely nothing happens when I click it.

There seems to be a couple of known bugs that are related to this, especially:
http://support.microsoft.com/?kbid=889877
and maybe this one:
http://support.microsoft.com/default...;en-us;q324735

I have tried running aspnet_regiis.exe -c but there is no difference.
I'm running .net framework 1.1 on a win2k3 server.

Any ideas are appreciated. Thanks.

Feb 6 '06 #15

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

Similar topics

1
by: Pete Mahoney | last post by:
Ok I use a textarea to store data input by the user, and then upon them clicking the submit button I store this data to a database. The problem is once the user inputs too much data (about 3...
1
by: Jie | last post by:
Hi, All I am use Web User Control for State/Province drop down list. Public Class TEQContactCreate Inherits TEQBasePage Protected ddlProvinceFilter As ProvinceDropDownList Protected...
6
by: Steve | last post by:
Hi, I open up a webform (vb.net) and populate a listbox control on the Page load event. If I click on (select) and item from the listbox I want to write the value of the selected item to a...
9
by: Jonathan Wood | last post by:
Does anyone know of any reason a button on a master page would have no effect? I have a complex HTML page that I'm converting to ASP.NET, and acknowledge I could have something odd that is...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
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...
0
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...

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.