Jaa


Building custom popup controls

I heard more than few times question on how to build combobox like dropdown custom control where clicking on dropdown will show a treeview, a checked listbox or any user control. One example is the dropdown tree control for Area and Iteration paths. To save space in work item form, it is nice idea to build custom controls which dropsdown for viewing more data. And it is quite easy to do it with VS 2005 actually (When I built the areapath control, toolstrip controls weren't available so I had to do it hard way).

Here is a post on how to build such dropdown tree control using toolstrip functionalities in VS2005: https://blogs.msdn.com/jfoscoding/archive/2005/09/18/471048.aspx . The article here gives almost complete code to add an usercontrol as dropdown control: https://www.windowsforms.net/FAQs/default.aspx?PageID=2&ItemID=788&CategoryID=3&tabindex=3 . One useful implementation would be to dropdown a listbox with checkboxes to choose multiple values - it could be saved as comma delimited values in fields. Ofcourse, IWorkItemControl interface needs to be implemented as described in my custom control post.

Comments

  • Anonymous
    August 06, 2007
    I'm in process of making similar control - it should act like Iteration/Path controls. Suggested values should be editable like Iteration and Path. Where to sore them? I suppose them should be stored as xml fragment. Note: When storing suggested values in work item definition xml, this causes strange error: <ALLOWEDVALUES>    <LISTITEM value="Root" />    <LISTITEM value="RootChild1" />    <LISTITEM value="RootChild2" />    <LISTITEM value="RootChild1Child11" />    <LISTITEM value="RootChild1Child12" />    <LISTITEM value="RootChild2Child21" />    <LISTITEM value="RootChild2Child22" /> </ALLOWEDVALUES> TF26171: User/group 'RootChild1' is not found.