Server Error in Application

An unhandled exception occurred during the execution of the current web request
posts - 60, comments - 76, trackbacks - 54

My Links

News

My Bookmarks

Archives

Post Categories

ASP.NET

All selected values from a CheckBoxList ASP.NET

 

private Int32[] CheckboxListSelections(System.Web.UI.WebControls.CheckBoxList list)

    {

        ArrayList values = new ArrayList();

        for (int counter = 0; counter < list.Items.Count; counter++)

        {

            if (list.Items[counter].Selected)

            {

                values.Add(list.Items[counter].Value);

            }

        }

        return (Int32[])values.ToArray(typeof(Int32));

    }


ASP.NET Interview Questions | C# Interview Questions | .NET Interview Questions | Dot Net Interview Questions | VB.NET Interview Questions | Oracle Interview Questions

Print | posted on Wednesday, October 25, 2006 5:20 PM | Filed Under [ ASP.NET ]

Feedback

Gravatar

# re: All selected values from a CheckBoxList ASP.NET

This Is A Very Good Post
Thanks a lot
9/2/2007 7:57 PM | Gersy

Post Comment

Title  
Name  
Email
Url
Comment   
Please add 8 and 3 and type the answer here:

Powered by: