Questions tagged [onclick]

An event which occurs when user clicked an object. It is a combination of two events, that is, "onmousedown" and "onmouseup".

Tag Usage

This tag is used frequently on questions surrounding Javascript event handling. It is worth noting that virtually every conceivable question has been asked on this topic so before you hit that post your question button, have you had a quick look to see if your question has already been covered?

14616 questions
2
votes
1 answer

ASP.NET Textbox TextChanged and Button OnClick event interaction?

I've got an ASP.NET application that I'm accessing through Google Chrome. On a particular page I've got an asp:TextBox with a OnTextChanged event that recalculates a few other fields on the page. I've also got an asp:LinkButton with an OnClick…
busoni34
  • 389
  • 1
  • 4
  • 13
2
votes
3 answers

View.OnClickListener() in Android responding for the wrong button

I am having an issue registering a call when a button is clicked. I have 2 EditTexts, one Button and one CheckBox. I would like to get the onClick() function called when the Button is pressed. Unfortunately, it only happens when the CheckBox is…
Jary
  • 1,501
  • 3
  • 24
  • 35
2
votes
1 answer

TextBox OnClick Event - What was clicked?

My problem is that i have a onClick on my TextBox, which sets the value to nothing. Like this: So if the i click on the next TextBox…
Toby
  • 95
  • 1
  • 10
2
votes
2 answers

How to make a linkbutton onclick with parameters

HTML : ')" > CodeBehind: protected void viewProductImage(object sender, EventArgs…
AndyC
2
votes
3 answers

onclick event of the link button inside the reapeator control fires at the time of binding data to reapeator control

I have a Linkbutton inside a Repeater control. My code in the aspx page :
BumbleBee
  • 10,429
  • 20
  • 78
  • 123
2
votes
1 answer

Input in appwidget

What's the best way of getting input from appwidget. I know that I can use setOnClickPendingIntent method from RemoteViews, but I don't want that! Is there any alternative ways ? P.S. When i'm trying to register onClick listener in Xml (
holtaf
  • 787
  • 6
  • 19
2
votes
1 answer

How do I build an accelerating scroll affect using javascript?

I am new to javascript, which so many of you know, and I am finding that the actual application of all the things I learned evades me. If you just give me the code, that probably won't help me; I need a break down of how and why things work as far…
Marlon
  • 597
  • 2
  • 8
  • 17
2
votes
0 answers

My onClick callback seems to be out of sync with my POST request

Hopefully I can explain the issue I'm having. I have a button that triggers a callback function to initiate a POST request, aiming to save favorite job posts. The endpoint for this request is connected to my backend using Python with Flask. In the…
2
votes
1 answer

Javascript onclick event takes two clicks

I am trying to figure out how to make this one click event to take only one click, as it currently takes two. Before I had the on click event inline, but after reading here, I changed it to the code below but still did not work. const input =…
2
votes
1 answer

What should I do instead of using Onclick? And how to fix positioning

I have 2 questions 1: I am very new to coding so I showed my code to others and was told I should not be using onclick but have no idea how to rewrite as something else. 2: When I first launch the code or refresh it the Borderlands button when…
2
votes
1 answer

onclick='' is not working when trying a Chrome extension

I am trying to make a Chrome extension however onclick='' is not working when used due to inline javascript below is the code I use: let createTasks = () => { TaskContainer.innerHTML = `My Tasks` …
Mehdi
  • 57
  • 5
2
votes
3 answers

Detecting Href Is Clicked

I'm trying to detect if certain element is clicked on onbeforeunload. I can't get it to work. Below is examples of the Javascript code and HTML code on the project (Please note that I have no control over the HTML element as it is not my…
jeezyfreezy
  • 182
  • 2
  • 12
2
votes
3 answers

how to make dialog box appear on the left?

I want to add OnclickListener for a button,where in I want to display the Dialog box on the left of the screen on click of it.I tried to implement that but it always appears on the center of the screen.Any idea on how to implement that?
Jack Dsilva
  • 1,504
  • 3
  • 24
  • 44
2
votes
1 answer

Onclick Event Issue in IE 7

I'm thoroughly confused now. Exclusively in IE7 my onclick function fails to execute. However, when I run it in IE's console, it works just fine. I've tried the following combinations: onclick="loadStatsRSH('h',2)"…
Saahir Foux
  • 654
  • 4
  • 12
  • 27
2
votes
5 answers

How to hide a div after click on another div

I want to hide my div after click on a search icon, it isn't a button so I don't really know how to do it. I want to hide this text " Simply click on the … and type the name of where you would like to visit" by clicking on the div…
moni_maj89
  • 25
  • 4
1 2 3
99
100