Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CheckedListBox, ListBox, ListView, or DataGridView

Status
Not open for further replies.

Auguy

Programmer
Joined
May 1, 2004
Messages
1,206
Location
US
I need some guidance/best approach on which control to use. On my UserID form I would like to have a display of all of the groups the user is a member of. The possible groups are in a SQL table and the groups this user is a member of are in another table. I would like to just display the current groups until the "Edit" mode is invoked and then display a list of all of the groups with the current groups for this user checked or in some way indicated (Back color, etc.). Then the user can click to choose the groups. I'm leaning towards a datagridview with a filter for selected/not selected depending on the "Edit" mode. I'm using VB.net 2008 and SQL 2005.

Auguy
Northwest Ohio
 
That is going to really be preference with no better or worse in my experience. The best suggestion is go with which ever is more comfortable for you to work with. Personally I just don't like DataGridViews normally. I don't like databinding and see no reason to late bind one. If I wanted something like that it is often just as easy to make it in Access then. Still that is just a quirk of mine.

In this instance I personally would tend to use a CheckListBox. If I have subset of information like a description or if I was working with files and wanted to display name separate from Full Path then I would use a ListView. For instance if you wanted to have the groups description easily shown along with their name then I would use a ListView with check boxes.

-I hate Microsoft!
-Forever and always forward.
-My kingdom for a edit button!
 
Thanks Sorwen. Just as I posted my thread I saw this thread (Is checkedlistbox the way to go) that is very similar to mine.

Auguy
Northwest Ohio
 
np. :)

-I hate Microsoft!
-Forever and always forward.
-My kingdom for a edit button!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top