OpenDCL Forums

OpenDCL => Runtime/AutoLISP => Topic started by: Woabow on December 02, 2011, 05:09:01 AM

Title: DWGPreview
Post by: Woabow on December 02, 2011, 05:09:01 AM
In Bricscad I'm having trouble viewing a DWG in the DGWPreview box. When initialising the Form the preview appears, but I'm not able to switch the content.

I have created a smal testproject with the minimum of code, but it still doesn't work.

Am I doing something wrong?


(defun c:btst ( /   )
(command "_OPENDCL")
(dcl_Project_Load "btst")
(dcl_Form_Show btst_Form1)
)

(defun c:btst_Form1_OnInitialize (/)
(dcl_ListBox_Clear btst_Form1_ListBox1)
(setq fullpathlist '("e:\\temp\\block1.DWG" "e:\\temp\\block2.DWG" "e:\\temp\\block3.DWG"))
(dcl_ListBox_AddList btst_Form1_ListBox1 fullpathlist)
(dcl_DwgPreview_LoadDwg "btst" "Form1" "DwgPreview1" (nth 1 fullpathlist)) ;this preview will show up
)


(defun c:btst_Form1_ListBox1_OnSelChanged (ItemIndexOrCount Value /)
      (dcl_Control_SetCaption btst_Form1_Label1 Value) ; to check the value
      (dcl_DwgPreview_LoadDwg "btst" "Form1" "DwgPreview1" Value) ;box will be cleared at this point
)


(princ)
Title: Re: DWGPreview
Post by: owenwengerd on December 02, 2011, 12:13:57 PM
I'm pretty sure this is a Bricscad bug, and I recommend reporting it to them directly.
Title: Re: DWGPreview
Post by: roy_043 on December 02, 2011, 12:50:55 PM
Here you will find the same problem (with a work-around):
http://www.opendcl.com/forum/index.php?topic=1710.0 (http://www.opendcl.com/forum/index.php?topic=1710.0)

Based on Owen's comment in that thread I assume it is an ODCL issue:
Quote from: owenwengerd on October 23, 2011, 06:56:59 PM
Good catch. This is now fixed for the next build.
Title: Re: DWGPreview
Post by: owenwengerd on December 02, 2011, 01:22:03 PM
Good catch, I forgot about that one.
Title: Re: DWGPreview
Post by: Woabow on December 05, 2011, 01:05:21 AM
Thanks for the workaround, now I finally can see the previews in the second page of my browser and the speed is still good.



Title: Re: DWGPreview
Post by: andrew on December 06, 2011, 11:03:31 AM
heh, i just noticed mine doesnt see the dwgpreview either...

meh, ill just wait for the fixed release instead of using the work around. im to lazy to modify my code for it.

thanks for your suggestion though