?
Solved

disable options in multiselect

Posted on 2009-04-05
5
Medium Priority
?
972 Views
Last Modified: 2012-05-06
Hi All,
I have a multiselect drop down . At first users lets think it is "new" mode users will submit this multiselect drop down and value/values will be stored in database( I have 5 values in drop down)
now in "update" mode again users will try to submit by selecting more values from this multiselect drop down, but I want to stop and show them a alert as soon as submit all the values in the drop down , i.e out of 5 they can select upto 4 , but if they select the 5th one ,I should leave the values which came from database and I should deselect recently selected values.
 I hope I am clear.
Thanks in adavance.
0
Comment
Question by:prk_usa
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 53

Expert Comment

by:Ryan Chong
ID: 24074127
>>i.e out of 5 they can select upto 4 , but if they select the 5th one ,I should leave the values which came from database and I should deselect recently selected values.

Why not generate a checkboxes list instead? Which i think more user friendly and easier for your scripting?
0
 

Author Comment

by:prk_usa
ID: 24074174
Thanks for your response ryancys. but  I have existing feature as mentioned above.
 
 
 
 
0
 
LVL 11

Accepted Solution

by:
Manish earned 1500 total points
ID: 24075784
Iterate through selected values, check size and show alert.
ex.
http://www.ozzu.com/programming-forum/javascript-get-value-multiple-options-from-select-t88883.html
0
 
LVL 11

Expert Comment

by:Manish
ID: 24075839
0
 

Author Closing Comment

by:prk_usa
ID: 33056268
good
0

Featured Post

Enroll in August's Course of the Month

August's CompTIA IT Fundamentals course includes 19 hours of basic computer principle modules and prepares you for the certification exam. It's free for Premium Members, Team Accounts, and Qualified Experts!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

We are witnesses that everyone is saying that our children shouldn't "play" with a technology because it is dangerous. This article is going to prove that they are wrong.
If you're a modern-day technology professional, you may be wondering if certifications are really necessary. They are. Here's why.
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Suggested Courses
Course of the Month9 days, 13 hours left to enroll

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question