OpenDCL Forums

OpenDCL => Runtime/AutoLISP => Topic started by: velasquez on January 04, 2009, 03:34:44 AM

Title: Problem with Dockable Form.
Post by: velasquez on January 04, 2009, 03:34:44 AM
HI  javascript:void(0);
The code that I posted doesn't work with Dockable Form
That is normal?

(defun c:DclForm1_OK_OnClicked ()
    (dcl_Form_Close diatest_DclForm1)
    (setq nextDlg 2)
)

(defun c:DclForm2_OK_OnClicked ()
    (dcl_Form_Close diatest_DclForm2)
    (setq nextDlg 1)
)
;;;
(defun c:test (/ nextDlg)
  (setq nextDlg 1)
  (while (/= nextDlg NIL)
    (cond
      ((= nextDlg 1)
       (setq nextDlg Nil)
       (dcl_Form_Show diatest_DclForm1)
      )
      ((= nextDlg 2)
       (setq nextDlg nil)
       (dcl_Form_Show diatest_DclForm2)
      )
    ) ;_ fim de cond
  ) ;_ fim de while
) ;_ fim de defun


Title: Re: Problem with Dockable Form.
Post by: owenwengerd on January 04, 2009, 07:10:14 AM
Did you expect the while loop to continue while the dialogs are displayed?  If that was your intention, it will not continue because you set nextDlg to NIL inside the loop.  Just change your OnClicked handlers to open the appropriate "next" dialog.
Title: Re: Problem with Dockable Form.
Post by: velasquez on January 05, 2009, 04:42:50 AM
Hi Owen, 
I didn't understand your answer well. 
I posted the files.lsp and odcl. 
This code works well with Modal Form.

I thank if you can me to show how it works with Dockable.
Title: Re: Problem with Dockable Form.
Post by: velasquez on January 08, 2009, 02:44:56 AM
Hi, 
Could anybody test the files that I posted and to tell me which my mistake? 
Thanks 
Title: Re: Problem with Dockable Form.
Post by: BazzaCAD on January 09, 2009, 02:05:35 PM
Try this....
But wouldn't it be easier to just use a Palette...
Title: Re: Problem with Dockable Form.
Post by: velasquez on January 10, 2009, 03:54:02 AM
Hi Barry 
Your code worked perfectly. 
I am using this to simulate a Palette in OpenDcl 4.1.2.2 
Thank you very much for your help.