About control
Browser compatibility: FireFox, Safari, Chrome, Opera (latest versions, May 2011), Internet Explorer 8.0
Server side: ASP.NET Web Forms 3.5, 4.0, can work with both synchronous postbacks and asynchronous when the control is placed within UpdatePanel control
The control is directly inherited from CheckBoxList control and thus can be used in place of it (easy migration is possible):
public class DropDownCheckBoxes : CheckBoxList, IPostBackEventHandler
{
...
The assembly containing control class also has embedded web resources used by the control which are automatically streamed to the browser:
- Client side JavaScript
- CSS file
- Button images
- jQuery script
Note: The jQuery JavaScript library is required for control proper functioning. The library is delivered within the assembly and is automatically referenced whenever the control is added to a page. To avoid duplicate references this behavior can be turned off by setting 'IncludeJqueryScript' property.
Getting started
The process of adding the control to project is absolutely the same as for other server controls.
1. In order to start using the control in you ASP.NET application get the control assembly from project's download page.
2. After you have DropDownCheckBoxes.dll downloaded you should add references to the assembly. Right click the web application project node in the solution explorer, choose 'Add reference' and in the dialog appeared find path to the downloaded .DLL file.
3. Register the control by adding web.config setting (if there's already
<system.web>
<pages>
<controls>
<add tagPrefix="asp" namespace="Saplin.Controls" assembly="DropDownCheckBoxes"/>
</controls>
</pages>
</system.web>
4. Put the control to .aspx page
<asp:DropDownCheckBoxes ID="yearsDropDownCheckBoxes" runat="server">
</asp:DropDownCheckBoxes>
The project page at Codeplex can be found here.
how i can change the width and font of dropdownchekboxes?
ReplyDeleteMaxim Saplin Blog: Dropdowncheckboxes: Introduction >>>>> Download Now
Delete>>>>> Download Full
Maxim Saplin Blog: Dropdowncheckboxes: Introduction >>>>> Download LINK
>>>>> Download Now
Maxim Saplin Blog: Dropdowncheckboxes: Introduction >>>>> Download Full
>>>>> Download LINK 1e
I need drop down check box ddl for asp.net 2.0 framework.
ReplyDeleteCan any one help me for this?
Hey All, I want to check all in the dropdown..do we have any shortcut to do it...I have thousands items in the dropdown...looping is making my page slow...how to automatically make it selected?
ReplyDeleteforeach (ListItem item in DD.Items)
{
item.Selected = true;
}
No list should ever have thousands of items in it. If that is the case some process needs to precede the ability to select an item that limits the list. Universe - Galaxy - Solar system - planet. Get it?
Deleteforeach (ListItem item in DD.Items)
ReplyDelete{
if(item.Selected)
{
//my code here
}
}
here in if conditoin item.selected is giving 'false' for selected items also
please help me
How to validate these Dropdowncheckboxes ???
ReplyDeleteMy issue also. Any body?
DeleteDrop Down list SelectedIndexChanged Event is firing twice plz help me
ReplyDeletedoes this control work in user control and internet explore 7.0
ReplyDeleteHi,
ReplyDeleteIs there a way to disable the control so that the user is not able to click it? Currently it only disable drop down items, not the control itself.
Dropdowncheckboxes not maintaining its checked state after binding filter data to gridview please advice me
ReplyDeleteThis i am binding to dropdowncheckboxes after filtering
--------------
DataTable dtProName = dtgridview.DefaultView.ToTable(true, "Exec_BlockName");
ProjectType.DataSource = dtProName;
ViewState["prType"] = dtProName;
ProjectType.DataTextField = "Exec_BlockName";
ProjectType.DataBind();
foreach (ListItem item in (ProjectType as ListControl).Items)
{
item.Selected = true;
}
----------------------------------------
Please advice any one knows how to maintain checked state of items after filtering
Note: Dropdowncheckboxes controls are inside of gridview and update panel
Thanks in Advance.
when i put may grid in update panel then drop down checkbox list list not show in grid. it show error like this 'ReferenceError: DropDownScript is not defined'
ReplyDeletePlease Help Me.
DeleteLike the control do you know how I can pass entire selections into a parameter for a report that accept multiple values from vs2010 C#.net?
DeleteLike the control but how do I pass entire selections to a report parameter that accept multi-values using vs2010 C#.net?
ReplyDeleteI used the following code to solve my problem. Thanks for creating the dropdowncheckbox control, it is very handy.
Deletepublic string[] fieldName
{
get
{
System.Collections.ArrayList arrayList = new System.Collections.ArrayList();
foreach (System.Web.UI.WebControls.ListItem item in DropDownCheckBoxes.Items)
{
if (item.Selected)
{
arrayList.Add(item.Value);
}
}
return (String[])arrayList.ToArray(typeof(string));
}
}
This comment has been removed by the author.
ReplyDeleteIs there a way to disable the control so that the user is not able to click it? Currently it only disable drop down items, not the control itself.
ReplyDeleteHow will I change the the width? please let me know. Thanks
ReplyDeleteYou can set the select box width under the DropDownCheckBoxes tag like as bellow
DeleteStyle SelectBoxWidth="20%"
How can we access the control in javascript like another dropdownlist document.getElementById('ddl').options.length..?
ReplyDeleteHow can we check the all checkboxes of the control, when page load time i.e.defaultly
ReplyDeleteI also need drop down check box ddl for asp.net 2.0 framework.
ReplyDeleteCan any one help me for this?
the SelectedIndexChanged event fires two times?
ReplyDeleteHello,
ReplyDeletefirst i wanna thank for this awesome control.
My question is how do we change the height and fornt of the selectbox. i know changing the width of select box or hewight of dropdown box but same pattern did not work fro the height or font of the select box.
thanks already.
Hi,
ReplyDeleteI have set UseButton=true as i want the user to click the Ok button after he is done selecting items.
Could anyone let me know how to set the fontsize of the button caption when UseButton=true?
Also i see the SelectedIndexChanged event is getting fired twice. Is there anyway to stop this?
Any help is a welcome.
Thanks in advance.
Hi,
ReplyDeleteBrilliant work and thanks for the effort. Do you perhaps have a Radio Button list control?
Thanks
I can see no need for a radio button list control. If multiple radio buttons can be selected then it is the same as check boxes. If only one selection is allowed (grouped) then what is the point?
Deleteclick event is not working for me.
ReplyDeleteclick event is not working for me. please help
ReplyDeleteThe dropdown is not working in
ReplyDeleteHow do I widen the DDL? the list is too narrow and my checkboxes are displaying above instead of adjacent to the labels.
ReplyDeleteThis comment has been removed by the author.
ReplyDeleteI try to user a DropDownCheckBoxes inside gridview, but in run time occurs an error
ReplyDeleteUncaught ReferenceError: DropDownScript is not defined
at :1:71
at Sys$_ScriptLoader$_loadScriptsInternal [as _loadScriptsInternal] (ScriptResource.axd)
Hi! I have the same problem xD
Delete-Rui Pinto
Hi, Even I am getting same error.. you guys have fix for this?
DeleteWow it is really wonderful and awesome thus it is very much useful for me to understand many concepts and helped me a lot. it is really explainable very well and i got more information from your blog.
ReplyDeleteData Science Training in Indira nagar
Data Science training in marathahalli
Data Science Interview questions and answers
Data Science training in btm layout
Data Science Training in BTM Layout
Data science training in bangalore
i have a problem using DropdownCheckbox. I dont want the SelectAll option,so i kept UseSelectAllNode="false".
ReplyDeleteBut i want a Deselect All option, how can i add a button for the same or make use of "Cancel" button which helps to clear selected options...plz help
Great control. I'm using it in a gridview control to display the results of a many to many database relationship. It gets populated just fine for each row in the gridview during the RowDataBound event, but when I edit the gridview, the dropdowncheckbox loses it's contents. Any ideas?
ReplyDeleteReferencing jquery.js on the page causing problem to open dropdown panel. Plz suggest.
ReplyDeleteUn artículo muy útil. Muy interesante leer este artículo.Me gustaría agradecerles el esfuerzo que han hecho por escribir este increíble artículo.
ReplyDeletehttps://www.safecasinosite.net
Smm Panel
ReplyDeleteSmm Panel
iş ilanları
instagram takipçi satın al
hirdavatciburada.com
beyazesyateknikservisi.com.tr
SERVİS
tiktok jeton hilesi
This blog is really helpful for the public .easily understand,
ReplyDeleteThanks for published,hoping to see more high quality article like this.
홀덤사이트