Go Back   CodingForums.com > :: Client side development > JavaScript programming > JavaScript frameworks

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 01-02-2012, 11:40 PM   PM User | #1
sachinmaster
New to the CF scene

 
Join Date: Dec 2011
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
sachinmaster is an unknown quantity at this point
incorrect number is displayed

When the user clicks on the "Select All Buttons" button, it should display a number in the Number of answers text-box (.numberAnswerTxt) which is the number of buttons that are selected but it is not quite displaying this.

Follow the steps in my fiddle to be able to see what is happening:

Step 1: open the grid and select option "4". Buttons A to D would be displayed.

Step 2: Click on the "Select All buttons" buttons, this selects all the buttons A to D (they all turn green) and in the number of answers textbox it shows the number 4 as all 4 buttons are selected.

Step 3: Click on the "Add Question" button, This adds a new row showing the details you have entered.

Step 4: now open the grid again at the top and select option 6, Now click on the "Select All Answers" button, all 6 buttons have been selected (A to F) and the number of answers textbox displays the number 6.

Step 5: For the last time open the grid and select option 4 again, now you see 4 buttons (A to D) all selected yet the textbox still states 6 even though the it should display 4 as you only see 4 buttons selected.

So in the example above what needs to happen so that the number 4 is displayed except for the number 6?

code is in jsfiddle click http://jsfiddle.net/uXZcC/21/
sachinmaster is offline   Reply With Quote
Reply

Bookmarks

Tags
dom, jquery

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 08:33 AM.


Advertisement
Log in to turn off these ads.