Update: Metabuilders.com updated their controls for Net 2.0!
Metabuilders had a free ASP.Net web control (with source) called DualList (or DynamicListBox) that worked really well in ASP.Net 1.1. I wanted to use it in 2.0 but there are some minor fixes needed in the code. Here is summary of the fixes I found here and here.
Combining this control with Telerik‘s AjaxManager is slick.
Steps to Convert DualList to ASP.Net 2.0
- First download the source from the metabuilders web site. Open the solution in VS 2005 and it will start the conversion wizard. When it asks about not finding the source code bindings, choose to remove them.
-
Once the conversion is finished, the project will not compile. Open the AssemblyInfo.cs file and REMOVE:
[assembly: AssemblyDelaySign(false)]
[assembly: AssemblyKeyFile(“”)]
[assembly: AssemblyKeyName(“metabuilders.com”)] -
Now open DynamicListBoxResourceHandler.cs, REPLACE:
if ( context.Cache[cacheKey] == null ) {
context.Cache.Insert(cacheKey, DetermineIsRegistered());
}
return (Boolean)context.Cache[cacheKey];WITH:
bool bRet=false;
//fixed cache delay, do not rely on cache available immediately after insert
if (context.Cache[cacheKey] == null)
{
bRet = DetermineIsRegistered();
context.Cache.Insert(cacheKey, bRet);
}else
bRet = (Boolean)context.Cache[cacheKey];
return bRet;
-
In DynamicListBoxResourceHandler.cs again, REPLACE:
Object handlerMap = System.Web.HttpContext.GetAppConfig(“system.web/httpHandlers”);
WITH:
Object handlerMap = System.Web.HttpContext.GetAppConfig(“httpHandlers”);
-
Finally, in DynamicListBox.js, REPLACE:
list.Tracker = DynamicListBox_FindControl( list.name + “:itemTracker” );
WITH:
list.Tracker = DynamicListBox_FindControl( list.name + “$itemTracker” );
You should be all set then.
May 10th, 2007 at 4:34 am
Thanks, good work.
June 28th, 2007 at 9:32 am
Greatï¼Could you please send me a copy of working souce code?
Thanks!
July 31st, 2007 at 5:40 am
Hi you,
I can’t download source and dll of DynamicListBox from Metabuilders.com . I don’t know what the problems the site has. Would you mind sending me its source? I’ll try your guide because I also need a dual list box control for .NET 2.0
August 14th, 2007 at 12:10 pm
The change for DynamicListBox.js isn’t working for me. After doing some testing, it would appear my controls are named with a : not a $. With the $, I get a JS error (the find fails) – putting the : back in works fine.
?
January 29th, 2008 at 3:34 pm
this article is titled reviving the duallist yet the subject matter is in regards to the dynamic list.
January 29th, 2008 at 6:06 pm
oops the duallist relies on dynamiclist…my mistake
November 10th, 2011 at 5:13 pm
I must express some thanks to you just for rescuing me from this type of incident. Right after surfing through the the web and finding notions that were not helpful, I assumed my life was done. Living minus the strategies to the difficulties you have fixed by way of your good article content is a critical case, and those which could have adversely damaged my career if I had not noticed your website. Your primary talents and kindness in playing with all the things was invaluable. I don’t know what I would’ve done if I hadn’t encountered such a subject like this. I can also now look forward to my future. Thanks for your time so much for your impressive and results-oriented help. I will not hesitate to refer your site to any person who desires guide on this subject matter.