Solved

Using dropdown and listboxes to enable user selection

Posted on 2014-01-10
4
145 Views
Last Modified: 2014-01-13
Please see the attached file.
The program should allow users to select one or more options from the dropdown boxes.  The selected option gets put into the listbox.  When the user presses apply filter the items in the list box get sent to the stored procedure.
To make it work I use textboxes and hidden fields with javascript.
I want to make the textboxes eg txtfilenamecode invisible or at least disabled.  However this causes the program to fail.  
Any suggestions?
FileCollection.txt
0
Comment
Question by:AlHal2
  • 2
  • 2
4 Comments
 
LVL 26

Expert Comment

by:Shaun Kline
ID: 39771002
What you are describing fits more inline when using the CheckboxList control. Is there a design reason that you are using drop-down controls and list boxes to allow for multiple selections?

You can make textboxes invisible the using CSS which will not affect postback that you comment about in the attachment. To do this, add either a CssClass with a "display: none;" or add directly to your control a style property.
0
 

Author Comment

by:AlHal2
ID: 39776002
How would you use a checkboxlist if a dropdownbox could have hundreds of items?  I found it clogged up the web page, so was seeking an alternative.
0
 
LVL 26

Accepted Solution

by:
Shaun Kline earned 250 total points
ID: 39776447
You can enclose your checkboxlist control in a DIV and apply CSS to the DIV to limit its size. The CSS looks something like this:
.checkBoxList {
  max-height:100px;
  height:auto !important;
  height:100px;
}

Open in new window

0
 

Author Closing Comment

by:AlHal2
ID: 39776560
thanks.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

In my previous article (http://www.experts-exchange.com/Programming/Languages/.NET/.NET_Framework_3.x/A_4362-Serialization-in-NET-1.html) we saw the basics of serialization and how types/objects can be serialized to Binary format. In this blog we wi…
This article describes relatively difficult and non-obvious issues that are likely to arise when creating COM class in Visual Studio and deploying it by professional MSI-authoring tools. It is assumed that the reader is already familiar with the cla…
A company’s greatest vulnerability is their email. CEO fraud, ransomware and spear phishing attacks are the no1 threat to a company’s security. Cybercrime is responsible for the largest loss of money to companies today with losses projected to r…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

947 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now