Well, I managed to get it working, using dispatch, and it does create a new com object named folder which returns a value. However, if I close the com connection and then try to do it again mirc has some memory errors and crashes, try this out for size:

alias cdlg {
comopen odlg Shell.Application
if ($comerr) {
echo comopen failed
comclose odlg
halt
}
var %dlg = $com(odlg,BrowseForFolder,3,int,0,string,Testing,uint,BIF_BROWSEINCLUDEFILES,dispatch*vfolder,odlg)
echo -a $com(odlg,vfolder)
comclose odlg
}

Just run /cdlg, pick a folder, and click ok, vfolder will return the result. Then run it again, pick a folder, it ok and BOOM memory errors.

Last edited by coolspot; 11/06/03 03:19 AM.