OpenDCL Forums

OpenDCL => Runtime/AutoLISP => Topic started by: docsaintly on August 05, 2009, 09:25:05 PM

Title: List Box returns nothing?
Post by: docsaintly on August 05, 2009, 09:25:05 PM
(defun c:lstBlocks_OnSelChanged (ItemIndex Value /)
   (dcl_messagebox (itoa ItemIndex) "")
   (dcl_DWGPreview_LoadDwg dwgPreview (strcat selectedfolder "\\" Value))
)

The "selectedfolder" var is gotten from the file dialog, i have verified it's contents. The messagebox always returns 0, and when I look at the Value, it always returns nothing. I'm a bit confused on this one. Any help is appreciated.
Title: Re: List Box returns nothing?
Post by: owenwengerd on August 05, 2009, 09:36:21 PM
A small sample project that demonstrates the problem would help.
Title: Re: List Box returns nothing?
Post by: docsaintly on August 05, 2009, 09:38:43 PM
If it's not a known problem it's probably just me, I worked around it with:
(setq NValue (last (dcl_ListBox_GetSelectedItems lstBlocks)))

edit: The only special circumstance i can think of is that i'm loading 13,000 items into the list box. As a sidenote, the listbox had no problem with me doing a vl-directory-files and dumping that list into the listbox, but the dwglist crashed the program and shot the memory through the roof when passed the directory name.