<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: get stuck with combined dialog box in Visual LISP, AutoLISP and General Customization Forum</title>
    <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7876237#M107111</link>
    <description>&lt;P&gt;Inspect the code step by step to learn how to handle the dialog box.&lt;/P&gt;&lt;P&gt;Attach lsp and dcl files.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="in process" style="width: 400px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/479199iB2AF7FF9A734F600/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Image_14.gif" alt="in process" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;in process&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; code:&lt;/P&gt;&lt;PRE&gt;&lt;FONT size="3"&gt;;;============================= C:selena ====================================;;
;; Jose L. García G. -  3/22/18                                              ;;
;;===========================================================================;;

(defun ctrls_OnOff (key / )
 (cond
  ((= key "2point")
   (mode_tile "2point_values" 0)
   (mode_tile "center_radius_values" 1)
  )
  ((= key "center_radius")
   (mode_tile "center_radius_values" 0)
   (mode_tile "2point_values" 1)
  )
 )
)

(defun C:selena ( /  idxDlg action)
 (or $option (setq $option "2point"))
 (or $x1 (setq $x1 0.0))
 (or $y1 (setq $y1 0.0))
 (or $x2 (setq $x2 1.0))
 (or $y2 (setq $y2 1.0))
 ;;-------------------
 (or $xr (setq $xr 0.0))
 (or $yr (setq $yr 0.0))
 (or $radius (setq $radius 1.0))
 
 ;;Load dialog box
 
 (if (null pos_Dlg_selena)(setq pos_Dlg_selena '(-1 -1)))
 (if (not (setq idxDlg (load_dialog "selena.dcl")))
  (progn (prompt "\nDCL file can not be loaded.!") (exit))
 )	  
 (setq action T)
 (while action
  (if (not (new_dialog "selena" idxDlg "" pos_Dlg_selena))
   (progn (prompt "\nThe definition can not be loaded.!") (exit))
  )
  ;;_____________________________________________
  ;;dialog box assignments:
  (set_tile "option" $option)
  (ctrls_OnOff $option)
  (set_tile "X1" (rtos $x1))
  (set_tile "Y1" (rtos $y1))
  (set_tile "X2" (rtos $x2))
  (set_tile "Y2" (rtos $y2))
  ;;__
  (set_tile "Xr" (rtos $xr))
  (set_tile "Yr" (rtos $yr))
  (set_tile "radius" (rtos $radius))

  ;;_____________________________________________
  ;;Dialog box actions:
  (action_tile "2point" "(setq $option $key)(ctrls_OnOff $key)")
  (action_tile "center_radius" "(setq $option $key)(ctrls_OnOff $key)")
  ;;2point_values:
  (action_tile "X1" "(setq $x1 (atof $value))")
  (action_tile "Y1" "(setq $y1 (atof $value))")
  (action_tile "X2" "(setq $x2 (atof $value))")
  (action_tile "Y2" "(setq $y2 (atof $value))")
  ;;center_radius_values:
  (action_tile "Xr" "(setq $xr (atof $value))")
  (action_tile "Yr" "(setq $yr (atof $value))")
  (action_tile "radius" "(setq $radius (atof $value))")
  ;;Buttons:
  (action_tile "cancel"  "(setq pos_Dlg_selena (done_dialog 0))")
  (action_tile "DoApply" "(setq pos_Dlg_selena (done_dialog 1))")

  ;;activate dialogue box:
  (setq action (start_dialog))

  ;;_____________________________________________
  (cond
   ((= action 0) ;;click on cancel button
    (setq action nil)
    (unload_dialog idxDlg)
   )
   ((= action 1) ;;click on Make Circle button
    (cond
     ((= $option "2point")
      (command "_.circle" "_2P" (list $x1 $y1) (list $x2 $y2))
     )
     ((= $option "center_radius")
      (command "_.circle" (list $xr $yr) $radius)
     )
    );c.cond
    (princ)
   )
  );c.cond
 );c.while

 (princ)
);c.defun
(princ)&lt;/FONT&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 22 Mar 2018 18:43:30 GMT</pubDate>
    <dc:creator>joselggalan</dc:creator>
    <dc:date>2018-03-22T18:43:30Z</dc:date>
    <item>
      <title>get stuck with combined dialog box</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7867778#M107108</link>
      <description>&lt;P&gt;I'm trying to create a dialog box to draw a circle which have 2 choice. First one is 2 point (2p) to draw a circle and the other is 1 point and radius. I create a radio list for that. What I want is when I click on 1 choice and another dialog box open and you can enter data on that dialog box and then when you click Ok. Autocad execute the command of drawing a circle. But my lsp and dcl codes don't work. Can sb explain to me? Here is my lsp and dcl code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;LSP code:&amp;nbsp;&lt;/P&gt;&lt;P&gt;(defun C:selena(/ dcl_id userclick)&lt;/P&gt;&lt;P&gt;(if (not (setq dcl_id (load_dialog "selena.dcl")))&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(princ"\n dcl file can not be loaded")&lt;/P&gt;&lt;P&gt;(exit)&lt;BR /&gt;&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(if (not (new_dialog "selena" dcl_id))&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(princ"\n the definition can not be loaded")&lt;/P&gt;&lt;P&gt;(exit)&lt;BR /&gt;&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(action_tile "2point" "(setq choice1 (atoi(get_tile \"2point\")))")&lt;/P&gt;&lt;P&gt;(action_tile "center_radius" "(setq choice2 (atoi(get_tile \"center_radius\")))")&lt;/P&gt;&lt;P&gt;(action_tile "accept" "(done_dialog 1)")&lt;/P&gt;&lt;P&gt;(action_tile "cancel" "(done_dialog 0)")&lt;/P&gt;&lt;P&gt;(set userclick (start_dialog))&lt;/P&gt;&lt;P&gt;(unload_dialog dcl_id)&lt;/P&gt;&lt;P&gt;(if userclick&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(if (= choice1 1)&lt;/P&gt;&lt;P&gt;(defun gomez (/ dcl_id1 userclick)&lt;/P&gt;&lt;P&gt;(if (not (setq dcl_id1 (load_dialog "gomez.dcl")))&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(princ"\n dcl file cann't be loaded")&lt;/P&gt;&lt;P&gt;(exit)&lt;BR /&gt;&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(if (not (new_dialog "gomez" dcl_id1))&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(princ"\n the definition can not be loaded")&lt;/P&gt;&lt;P&gt;(exit)&lt;BR /&gt;&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(action_tile "X1" "(setq X1 (atof(get_tile \"X1\")))")&lt;/P&gt;&lt;P&gt;(action_tile "Y1" "(setq Y1 (atof(get_tile \"Y1\")))")&lt;/P&gt;&lt;P&gt;(action_tile "X2" "(setq X2 (atof(get_tile \"X2\")))")&lt;/P&gt;&lt;P&gt;(action_tile "Y2" "(setq Y2 (atof(get_tile \"Y2\")))")&lt;/P&gt;&lt;P&gt;(action_tile "accept" "(done_dialog 1)")&lt;/P&gt;&lt;P&gt;(action_tile "cancel" "(done_dialog 0)")&lt;/P&gt;&lt;P&gt;(setq userclick (start_dialog))&lt;/P&gt;&lt;P&gt;(unload_dialog dcl_id1)&lt;/P&gt;&lt;P&gt;(if userclick&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(command "circle" "2p" (list X1 Y1) (list X2 Y2))&lt;BR /&gt;&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(alert"\n exit the program")&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;(if (= choice2 1)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(defun superman(/ dcl_id2 userclick)&lt;/P&gt;&lt;P&gt;(if (not (setq dcl_id2 (load_dialog "superman.dcl")))&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(princ"\n dcl file can not be loaded")&lt;/P&gt;&lt;P&gt;(exit)&lt;BR /&gt;&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(if (not (new_dialog "superman" dcl_id2))&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(princ"\n the definition can not be loaded")&lt;/P&gt;&lt;P&gt;(exit)&lt;BR /&gt;&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(action_tile "X" "(setq X (atof(get_tile \"X\")))")&lt;/P&gt;&lt;P&gt;(action_tile "Y" "(setq Y (atof(get_tile \"Y\")))")&lt;/P&gt;&lt;P&gt;(action_tile "radius" "(setq radius (atof(get_tile \"radius\")))")&lt;/P&gt;&lt;P&gt;(action_tile "accept" "(done_dialog 1)")&lt;/P&gt;&lt;P&gt;(action_tile "cancel" "(done_dialog 0)")&lt;/P&gt;&lt;P&gt;(setq userclick (start_dialog))&lt;/P&gt;&lt;P&gt;(unload_dialog dcl_id2)&lt;/P&gt;&lt;P&gt;(if userclick&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(command "circle" (list X Y) radius )&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(alert"\n exit the program")&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;(progn&lt;/P&gt;&lt;P&gt;(alert"\n exit the program")&lt;BR /&gt;&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;)&lt;BR /&gt;)&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;DCL code 1 :&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;selena&lt;/P&gt;&lt;P&gt;:dialog{&lt;/P&gt;&lt;P&gt;:boxed_column{&lt;/P&gt;&lt;P&gt;:boxed_radio_column{&lt;/P&gt;&lt;P&gt;:radio_button{&lt;/P&gt;&lt;P&gt;key="2point";&lt;/P&gt;&lt;P&gt;label="select 2 point on plane";&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;:radio_button{&lt;/P&gt;&lt;P&gt;key="center_radius";&lt;/P&gt;&lt;P&gt;label="select center and radius";&lt;/P&gt;&lt;P&gt;}&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;:row{&lt;/P&gt;&lt;P&gt;:button{&lt;/P&gt;&lt;P&gt;key="accept";&lt;/P&gt;&lt;P&gt;label="ok";&lt;/P&gt;&lt;P&gt;is_default=true;&lt;/P&gt;&lt;P&gt;is_cancel=true;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;:button{&lt;/P&gt;&lt;P&gt;key="cancel";&lt;/P&gt;&lt;P&gt;label="cancel";&lt;/P&gt;&lt;P&gt;is_default=true;&lt;/P&gt;&lt;P&gt;is_cancel=true;&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;DCL code 2:&amp;nbsp;&lt;/P&gt;&lt;P&gt;gomez&lt;/P&gt;&lt;P&gt;:dialog{&lt;/P&gt;&lt;P&gt;:boxed_column{&lt;/P&gt;&lt;P&gt;:row{&lt;/P&gt;&lt;P&gt;:edit_box{&lt;/P&gt;&lt;P&gt;key="X1";&lt;/P&gt;&lt;P&gt;label="X1";&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;:edit_box{&lt;/P&gt;&lt;P&gt;key="Y1";&lt;/P&gt;&lt;P&gt;label="Y1";&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;:row{&lt;/P&gt;&lt;P&gt;:edit_box{&lt;/P&gt;&lt;P&gt;key="X2";&lt;/P&gt;&lt;P&gt;label="X2";&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;:edit_box{&lt;/P&gt;&lt;P&gt;key="Y2";&lt;/P&gt;&lt;P&gt;label="Y2";&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;:row{&lt;/P&gt;&lt;P&gt;:button{&lt;/P&gt;&lt;P&gt;key="accept";&lt;/P&gt;&lt;P&gt;label="ok";&lt;/P&gt;&lt;P&gt;is_default=true;&lt;/P&gt;&lt;P&gt;is_cancel=true;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;:button{&lt;/P&gt;&lt;P&gt;key="cancel";&lt;/P&gt;&lt;P&gt;label="cancel";&lt;/P&gt;&lt;P&gt;is_default=true;&lt;/P&gt;&lt;P&gt;is_cancel=true;&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;DCL code 3 :&amp;nbsp;&lt;/P&gt;&lt;P&gt;superman&lt;/P&gt;&lt;P&gt;:dialog{&lt;/P&gt;&lt;P&gt;:boxed_column{&lt;/P&gt;&lt;P&gt;:row{&lt;/P&gt;&lt;P&gt;:edit_box{&lt;/P&gt;&lt;P&gt;key="X";&lt;/P&gt;&lt;P&gt;label="X";&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;:edit_box{&lt;/P&gt;&lt;P&gt;key="Y";&lt;/P&gt;&lt;P&gt;label="Y";&lt;/P&gt;&lt;P&gt;}&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;:edit_box{&lt;/P&gt;&lt;P&gt;key="radius";&lt;/P&gt;&lt;P&gt;label="radius";&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;:row{&lt;/P&gt;&lt;P&gt;:button{&lt;/P&gt;&lt;P&gt;key="accept";&lt;/P&gt;&lt;P&gt;label="ok";&lt;/P&gt;&lt;P&gt;is_default=true;&lt;/P&gt;&lt;P&gt;is_cancel=true;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;:button{&lt;/P&gt;&lt;P&gt;key="cancel";&lt;/P&gt;&lt;P&gt;label="cancel";&lt;/P&gt;&lt;P&gt;is_default=true;&lt;/P&gt;&lt;P&gt;is_cancel=true;&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;</description>
      <pubDate>Tue, 20 Mar 2018 11:08:56 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7867778#M107108</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-03-20T11:08:56Z</dc:date>
    </item>
    <item>
      <title>Re: get stuck with combined dialog box</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7868501#M107109</link>
      <description>One method:&lt;BR /&gt;You will need to create a WHILE/COND loop&lt;BR /&gt;to be able to switch to the second dialog&lt;BR /&gt;(and be able to return back to the first dialog).&lt;BR /&gt;&lt;BR /&gt;Another method:&lt;BR /&gt;Use (done_dialog 2) to move to the second dialog.&lt;BR /&gt;Consecutive IF statements will get you there.&lt;BR /&gt;&lt;BR /&gt;Where:&lt;BR /&gt;(setq sd (start_dialog))&lt;BR /&gt;&lt;BR /&gt;&amp;lt;-- the first dialog is closed at this point --&amp;gt;&lt;BR /&gt;&lt;BR /&gt;And&lt;BR /&gt;(if (= sd 0) --&amp;gt; Cancel&lt;BR /&gt;&lt;BR /&gt;(if (= sd 2) --&amp;gt; Open second dialog for input&lt;BR /&gt; while in here determine if user input is valid.&lt;BR /&gt; If not, done_dialog 0, otherwise done_dialog 1.&lt;BR /&gt;&lt;BR /&gt;(if (= sd 1) --&amp;gt; enter main code block and execute.&lt;BR /&gt;&lt;BR /&gt;Oh, and in your DCL code, is_default=true; appears&lt;BR /&gt;more than one time. The last one wins.&lt;BR /&gt;&lt;BR /&gt;???&lt;BR /&gt;</description>
      <pubDate>Tue, 20 Mar 2018 14:34:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7868501#M107109</guid>
      <dc:creator>scot-65</dc:creator>
      <dc:date>2018-03-20T14:34:30Z</dc:date>
    </item>
    <item>
      <title>Re: get stuck with combined dialog box</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7869008#M107110</link>
      <description>&lt;P&gt;Can you edit my lisp code. I don't have enough experience so can you show me?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Mar 2018 16:40:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7869008#M107110</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-03-20T16:40:49Z</dc:date>
    </item>
    <item>
      <title>Re: get stuck with combined dialog box</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7876237#M107111</link>
      <description>&lt;P&gt;Inspect the code step by step to learn how to handle the dialog box.&lt;/P&gt;&lt;P&gt;Attach lsp and dcl files.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="in process" style="width: 400px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/479199iB2AF7FF9A734F600/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Image_14.gif" alt="in process" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;in process&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; code:&lt;/P&gt;&lt;PRE&gt;&lt;FONT size="3"&gt;;;============================= C:selena ====================================;;
;; Jose L. García G. -  3/22/18                                              ;;
;;===========================================================================;;

(defun ctrls_OnOff (key / )
 (cond
  ((= key "2point")
   (mode_tile "2point_values" 0)
   (mode_tile "center_radius_values" 1)
  )
  ((= key "center_radius")
   (mode_tile "center_radius_values" 0)
   (mode_tile "2point_values" 1)
  )
 )
)

(defun C:selena ( /  idxDlg action)
 (or $option (setq $option "2point"))
 (or $x1 (setq $x1 0.0))
 (or $y1 (setq $y1 0.0))
 (or $x2 (setq $x2 1.0))
 (or $y2 (setq $y2 1.0))
 ;;-------------------
 (or $xr (setq $xr 0.0))
 (or $yr (setq $yr 0.0))
 (or $radius (setq $radius 1.0))
 
 ;;Load dialog box
 
 (if (null pos_Dlg_selena)(setq pos_Dlg_selena '(-1 -1)))
 (if (not (setq idxDlg (load_dialog "selena.dcl")))
  (progn (prompt "\nDCL file can not be loaded.!") (exit))
 )	  
 (setq action T)
 (while action
  (if (not (new_dialog "selena" idxDlg "" pos_Dlg_selena))
   (progn (prompt "\nThe definition can not be loaded.!") (exit))
  )
  ;;_____________________________________________
  ;;dialog box assignments:
  (set_tile "option" $option)
  (ctrls_OnOff $option)
  (set_tile "X1" (rtos $x1))
  (set_tile "Y1" (rtos $y1))
  (set_tile "X2" (rtos $x2))
  (set_tile "Y2" (rtos $y2))
  ;;__
  (set_tile "Xr" (rtos $xr))
  (set_tile "Yr" (rtos $yr))
  (set_tile "radius" (rtos $radius))

  ;;_____________________________________________
  ;;Dialog box actions:
  (action_tile "2point" "(setq $option $key)(ctrls_OnOff $key)")
  (action_tile "center_radius" "(setq $option $key)(ctrls_OnOff $key)")
  ;;2point_values:
  (action_tile "X1" "(setq $x1 (atof $value))")
  (action_tile "Y1" "(setq $y1 (atof $value))")
  (action_tile "X2" "(setq $x2 (atof $value))")
  (action_tile "Y2" "(setq $y2 (atof $value))")
  ;;center_radius_values:
  (action_tile "Xr" "(setq $xr (atof $value))")
  (action_tile "Yr" "(setq $yr (atof $value))")
  (action_tile "radius" "(setq $radius (atof $value))")
  ;;Buttons:
  (action_tile "cancel"  "(setq pos_Dlg_selena (done_dialog 0))")
  (action_tile "DoApply" "(setq pos_Dlg_selena (done_dialog 1))")

  ;;activate dialogue box:
  (setq action (start_dialog))

  ;;_____________________________________________
  (cond
   ((= action 0) ;;click on cancel button
    (setq action nil)
    (unload_dialog idxDlg)
   )
   ((= action 1) ;;click on Make Circle button
    (cond
     ((= $option "2point")
      (command "_.circle" "_2P" (list $x1 $y1) (list $x2 $y2))
     )
     ((= $option "center_radius")
      (command "_.circle" (list $xr $yr) $radius)
     )
    );c.cond
    (princ)
   )
  );c.cond
 );c.while

 (princ)
);c.defun
(princ)&lt;/FONT&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 22 Mar 2018 18:43:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7876237#M107111</guid>
      <dc:creator>joselggalan</dc:creator>
      <dc:date>2018-03-22T18:43:30Z</dc:date>
    </item>
    <item>
      <title>Re: get stuck with combined dialog box</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7878038#M107112</link>
      <description>&lt;P&gt;I almost understand your coding but just 1 more thing. Can you explain what is " $action" and "$key" where do you get that from? Esp "$" , is that a symbol for sth?&lt;/P&gt;</description>
      <pubDate>Fri, 23 Mar 2018 10:12:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7878038#M107112</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-03-23T10:12:16Z</dc:date>
    </item>
    <item>
      <title>Re: get stuck with combined dialog box</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7878360#M107113</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The action assigned by&amp;nbsp;&lt;STRONG&gt;action_tile&lt;/STRONG&gt;&amp;nbsp;supersedes the dialog box's default action (assigned by&amp;nbsp;new_dialog) or the tile's&amp;nbsp;action&amp;nbsp;attribute, if these are specified. The expression can refer to the tile's current value as&amp;nbsp;&lt;STRONG&gt;$value&lt;/STRONG&gt;, its name as&amp;nbsp;&lt;STRONG&gt;$key&lt;/STRONG&gt;, its application-specific data (as set by&amp;nbsp;client_data_tile) as&amp;nbsp;$data, its callback reason as&amp;nbsp;$reason, and its image coordinates (if the tile is an image button) as&amp;nbsp;$x&amp;nbsp;and&amp;nbsp;$y.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-left" image-alt="2018-03-23_13-00-16.png" style="width: 618px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/479572i497160FAA690EDAD/image-size/large?v=v2&amp;amp;px=999" role="button" title="2018-03-23_13-00-16.png" alt="2018-03-23_13-00-16.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;link:&lt;/P&gt;&lt;P&gt;&lt;A href="https://knowledge.autodesk.com/search-result/caas/CloudHelp/cloudhelp/2016/ENU/AutoCAD-AutoLISP/files/GUID-A9E2C14E-1352-4C7B-89F0-C86D3A86B19D-htm.html" target="_blank"&gt;action_tile (AutoLISP/DCL)&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;I usually use "$" for the variables that remains open in the document to be reused.&lt;BR /&gt;&lt;STRONG&gt;$option, $x1, $y1, $x2, $y2, $xr, $yr &lt;/STRONG&gt;and&lt;STRONG&gt; $radius&lt;/STRONG&gt; are program variables.&lt;BR /&gt;Maybe I used another symbol for these and their better understanding.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;regards.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Mar 2018 12:15:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/get-stuck-with-combined-dialog-box/m-p/7878360#M107113</guid>
      <dc:creator>joselggalan</dc:creator>
      <dc:date>2018-03-23T12:15:41Z</dc:date>
    </item>
  </channel>
</rss>

