button

addEvenListener doesn't work on dynamic button - javascript

断了今生、忘了曾经 提交于 2020-03-05 07:54:00
问题 So I'm currently busy with learning JavaScript. I created some dynamic buttons and I tried to add an addEvenListener to it. But it doesn't work and I can't figure it out why it doesn't work. I'm just testing some stuff and I try to create buttons with values from the localstorage. It is almost working, only the addEvenListener isn't working. I just want a simple alert with the key from the localstorage. for (var i = 0; i <= localStorage.length-1; i++) { var categoryButton = document

Javascript:: export to text file

浪尽此生 提交于 2020-02-28 06:03:55
问题 <!DOCTYPE html> <html> <head> <title> </title> <meta charset=utf-8> </head> <body> <table> <tr> <th>A</th> <th>B</th> <th>C</th> </tr> <tr> <td>Line #1</td> <td>SLTD</td> <td>32</td> </tr> <tr> <td>Line #2</td> <td>MKTD</td> <td>68</td> </tr> <tr> <td>Line #3</td> <td>LRTD</td> <td>55</td> </tr> <tr> <td>Line #4</td> <td>HAD</td> <td>47</td> </tr> </table> <button>Export to text file</button> <script> var theFirstChilds = document.querySelectorAll('table tr td:first-of-type'), text, i; text =

Check with adding / removing objects in VB6

萝らか妹 提交于 2020-02-25 04:19:27
问题 I have a query, I have this interface: The ComboBox are inside a UserControl, pressing the Add this UserControl button with the ComboBox adds the UserControl / ComboBox in a PictureBox: What I want is that, for example, when the user selects values ​​of the two ComboBox and press the button add these selected values ​​go to the PictureBox (below) and the values ​​that are selected in the UserControl are cleaned.I leave a picture of what I say, suppose the user selected the values ​​of the

Check with adding / removing objects in VB6

安稳与你 提交于 2020-02-25 04:17:12
问题 I have a query, I have this interface: The ComboBox are inside a UserControl, pressing the Add this UserControl button with the ComboBox adds the UserControl / ComboBox in a PictureBox: What I want is that, for example, when the user selects values ​​of the two ComboBox and press the button add these selected values ​​go to the PictureBox (below) and the values ​​that are selected in the UserControl are cleaned.I leave a picture of what I say, suppose the user selected the values ​​of the

Check with adding / removing objects in VB6

↘锁芯ラ 提交于 2020-02-25 04:17:01
问题 I have a query, I have this interface: The ComboBox are inside a UserControl, pressing the Add this UserControl button with the ComboBox adds the UserControl / ComboBox in a PictureBox: What I want is that, for example, when the user selects values ​​of the two ComboBox and press the button add these selected values ​​go to the PictureBox (below) and the values ​​that are selected in the UserControl are cleaned.I leave a picture of what I say, suppose the user selected the values ​​of the

AS3 How to make only 1 movieclip clickable at a time when there are multiple movieclips

冷暖自知 提交于 2020-02-24 11:20:33
问题 Ok, so I have a page with 5 movieclips/buttons on it. When you mouse over each one they light up (OVER state) and when you click on them they expand (DOWN state). The problem is if you have multiple movieclips expanded (in the DOWN state) they overlap and it looks awful. I want to code them so only 1 can be expanded at a time. How can I do this? I imagine I need an IF statement on each button like "If any other movieclips are in the DOWN state, then disable DOWN for this movieclip, if no

android - setBackground with checking android version not working

家住魔仙堡 提交于 2020-02-23 06:44:33
问题 I want change the background drawable of a button. My min. SDK version is 14. Therefore I check the current version, which is installed on the device: int sdk = android.os.Build.VERSION.SDK_INT; if(sdk < android.os.Build.VERSION_CODES.JELLY_BEAN) { buttonClubPublic.setBackgroundDrawable(buttonClubPublic.getContext().getResources().getDrawable(R.drawable.check_button)); buttonClubPrivate.setBackgroundDrawable(buttonClubPrivate.getContext().getResources().getDrawable(R.drawable.uncheck_button))

Get only unique names from more elements

我只是一个虾纸丫 提交于 2020-02-20 09:31:27
问题 I have dynamically rendered HTML that lists an undetermined number of radio buttons whose names represent some ids in a database. I need to collect all of the unique names of the radios. Here is an example: <input name="721" type="radio" value="A" /> <input name="721" type="radio" value="I" /> <input name="722" type="radio" value="A" /> <input name="722" type="radio" value="I" /> <input name="723" type="radio" value="A" /> <input name="723" type="radio" value="I" /> Checking the radios is NOT

Problem changing button size when pressed in Android

末鹿安然 提交于 2020-02-15 09:08:57
问题 I have tried changing the size of my button when I press it but nothing seem to work. The button is created in main.xml: <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent"> <Button android:layout_alignParentLeft="true" android:layout_height="90px" android:id="@+id/button1" android:layout_marginTop="120px" android:layout_width="90px" android:textSize="45px"

Problem changing button size when pressed in Android

风流意气都作罢 提交于 2020-02-15 09:08:56
问题 I have tried changing the size of my button when I press it but nothing seem to work. The button is created in main.xml: <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent"> <Button android:layout_alignParentLeft="true" android:layout_height="90px" android:id="@+id/button1" android:layout_marginTop="120px" android:layout_width="90px" android:textSize="45px"