<?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: zoom extents in one cmd. in Visual LISP, AutoLISP and General Customization Forum</title>
    <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14277763#M172741</link>
    <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt;&amp;nbsp;The reason I look for the title block in the move is that sometimes people leave junk in a layout for some reason so doing a move "All" would not locate the title block at a 0,0 point. This was done to match our company standard of title block has insert at 0,0. We had other programs like plot lisp's and they adhered to title block location. As well as I checked final plans and junk would be removed. Yes Zoom object is a good idea.&amp;nbsp;&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-inline" image-alt="SeaHaven_1-1790293979640.png" style="width: 400px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1662806iDAA799BC4DCFEAFC/image-size/medium?v=v2&amp;amp;px=400" role="button" title="SeaHaven_1-1790293979640.png" alt="SeaHaven_1-1790293979640.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;</description>
    <pubDate>Thu, 24 Sep 2026 23:55:43 GMT</pubDate>
    <dc:creator>Sea-Haven</dc:creator>
    <dc:date>2026-09-24T23:55:43Z</dc:date>
    <item>
      <title>zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000433#M47997</link>
      <description>&lt;P&gt;Is that possible to make a shortcut?&lt;/P&gt;&lt;P&gt;A shortcut cmd "zz" that could do zoom extends as below;&lt;/P&gt;&lt;P&gt;Command: Z&lt;BR /&gt;ZOOM&lt;BR /&gt;Specify corner of window, enter a scale factor (nX or nXP), or&lt;BR /&gt;[All/Center/Dynamic/Extents/Previous/Scale/Window/Object] &amp;lt;real time&amp;gt;: e&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 12 Mar 2022 09:51:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000433#M47997</guid>
      <dc:creator>smallƑish</dc:creator>
      <dc:date>2022-03-12T09:51:30Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000445#M47998</link>
      <description>&lt;P&gt;That is what the mouse wheel double click does.&lt;/P&gt;</description>
      <pubDate>Sat, 12 Mar 2022 10:01:07 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000445#M47998</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2022-03-12T10:01:07Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000448#M47999</link>
      <description>&lt;P&gt;omg !! lol&lt;/P&gt;</description>
      <pubDate>Sat, 12 Mar 2022 10:04:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000448#M47999</guid>
      <dc:creator>smallƑish</dc:creator>
      <dc:date>2022-03-12T10:04:46Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000510#M48000</link>
      <description>&lt;P&gt;BTW it's fairly easy to write such a shortcut routine. Just follow the command line.&lt;/P&gt;
&lt;P&gt;(defun c:zz () (command "zoom" "e") (princ))&lt;/P&gt;</description>
      <pubDate>Sat, 12 Mar 2022 11:07:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000510#M48000</guid>
      <dc:creator>ВeekeeCZ</dc:creator>
      <dc:date>2022-03-12T11:07:35Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000672#M48001</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/10577275"&gt;@smallƑish&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;here an LISP from &lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt;&amp;nbsp;:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="general"&gt;;;  ZoomAllLayouts.lsp
;;  Command names:
;;    ZLAL = Zoom Limits All Layouts
;;    ZEAL = Zoom Extents All Layouts
;;    ZAAL = Zoom All All Layouts
;;  Gets into all Layouts, goes to Paper Space and Zooms to the [Limits or
;;    Extents or All] in each; ends in Model Space and likewise Zooms there.
;;  Kent Cooper, last edited 2 April 2013

(defun ZAL (zopt / zd cmde exp)
  (defun zd (); = Zoom Determination
    (cond
      ((= zopt "L") (command (getvar 'limmin) (getvar 'limmax))); use Limits
      ((= zopt "E") (command "_extents"))
        ; Uses Extents option, not EXTMIN/EXTMAX System Variables,
        ; because those do not shrink on reduction of the actual extents
        ; until the next drawing regeneration or Zoom All-or-Extents, so
        ; using them could Zoom to a larger area than the current Extents.
      ((= zopt "A") (command "_all"))
    ); cond
  ); defun
  (setq
    cmde (getvar 'cmdecho)
    exp (= (getvar 'expert) 0)
  ); setq
  (if exp (setvar 'expert 1)); suppresses "About to regen -- proceed?"
  (setvar 'cmdecho 0)
  (foreach lay (layoutlist)
    (setvar 'ctab lay)
    (command "_.pspace" "_.zoom")
    (zd)
  ); foreach
  (setvar 'ctab "Model")
  (command "_.zoom")
  (zd)
  (if exp (setvar 'expert 0)); reset if changed
  (setvar 'cmdecho cmde)
  (princ)
); defun

(defun C:ZLAL (); = Zoom Limits All Layouts
  (ZAL "L")
); defun

(defun C:ZEAL (); = Zoom Extents All Layouts
  (ZAL "E")
); defun

(defun C:ZAAL (); = Zoom All All Layouts
  (ZAL "A")
); defun&lt;/LI-CODE&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;</description>
      <pubDate>Sat, 12 Mar 2022 14:05:39 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/11000672#M48001</guid>
      <dc:creator>bigcarl5000kg</dc:creator>
      <dc:date>2022-03-12T14:05:39Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274553#M172699</link>
      <description>&lt;P&gt;I found the ZEAL command a while back, and love it.&lt;BR /&gt;The only thing I don't like is when there are elements outside the title block area, and it truly zooms to extents.&lt;BR /&gt;I wish there were a version that would zoom to the sheet area only.&lt;/P&gt;</description>
      <pubDate>Tue, 22 Sep 2026 14:44:54 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274553#M172699</guid>
      <dc:creator>fkellogg</dc:creator>
      <dc:date>2026-09-22T14:44:54Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274566#M172700</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/3839696"&gt;@fkellogg&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;.... I wish there were a version that would zoom to the sheet area only.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Set your &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;L&lt;/STRONG&gt;&lt;/FONT&gt;imits to the sheet areas, and use the &lt;STRONG&gt;Z&lt;FONT color="#FF0000"&gt;L&lt;/FONT&gt;AL&lt;/STRONG&gt; command, which is for exactly that.&lt;/P&gt;</description>
      <pubDate>Tue, 22 Sep 2026 14:56:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274566#M172700</guid>
      <dc:creator>Kent1Cooper</dc:creator>
      <dc:date>2026-09-22T14:56:59Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274570#M172701</link>
      <description>&lt;P&gt;I will have to look to see if I have the ZLAL version of that.&lt;/P&gt;</description>
      <pubDate>Tue, 22 Sep 2026 15:00:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274570#M172701</guid>
      <dc:creator>fkellogg</dc:creator>
      <dc:date>2026-09-22T15:00:49Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274648#M172702</link>
      <description>&lt;P&gt;See lines 3 and 41-43 of the code at Message 5.&lt;/P&gt;</description>
      <pubDate>Tue, 22 Sep 2026 16:00:31 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274648#M172702</guid>
      <dc:creator>Kent1Cooper</dc:creator>
      <dc:date>2026-09-22T16:00:31Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274655#M172703</link>
      <description>&lt;P&gt;I already had ZLAL in a separate file, just forgot it was there, in all my excitement of finding ZEAL.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 Sep 2026 16:03:09 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14274655#M172703</guid>
      <dc:creator>fkellogg</dc:creator>
      <dc:date>2026-09-22T16:03:09Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14275235#M172710</link>
      <description>&lt;P&gt;Two parts to the zoom to title block in layouts, I would find the title block in the layout and force a move of all objects so title block is at 0,0 for other programs like our "Autoplot". So using same code can use Zoom "W" window by getting the "Bounding Box' of the title block.&lt;/P&gt;&lt;P&gt;This is the move part have a go at adding the zoom window. In our case the title block is known and at 1:1 true size so can do a zoom window -20,-20 then 821,574&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="general"&gt;; moves all objects in pspace to 0,0 alignment based on selected title block.
; By AlanH updated Oct 2025

(defun movelayouts ( / oldsnap plottablist xy)
  (setq oldsnap (getvar "osmode")) 
  (setvar "osmode" 0)
  
  (setq plottablist (layoutlist))
  (setvar 'ctab (nth 0 plottablist ))
  
  (setq  ent (entget (car (entsel "Pick Title Block:"))))
    (setq bname (cdr (assoc 2 ent)))
	
  (foreach tname plottablist
    (setvar "ctab" tname)
    (setq ss (ssget "X" (list (cons 0 "INSERT")(cons 2 bname)(cons 410 tname))))
    (setq xy (cdr (assoc 10 (entget (ssname ss 0)))))
    (command "move" "w" (getvar "extmax") (getvar "extmin")  "" xy "0,0")
    (command "zoom" "E") ; replace here zoom window
  )
  
  (setvar "osmode" oldsnap)
  (princ)
)
(movelayouts)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 23 Sep 2026 04:38:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14275235#M172710</guid>
      <dc:creator>Sea-Haven</dc:creator>
      <dc:date>2026-09-23T04:38:42Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14275660#M172713</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/6254908"&gt;@Sea-Haven&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;... use Zoom "W" window by getting the "Bounding Box' of the title block. ....&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;You could do it by just using the&lt;FONT face="courier new,courier"&gt;&lt;STRONG&gt; ZOOM&lt;/STRONG&gt; &lt;/FONT&gt;command's&lt;FONT face="courier new,courier"&gt;&lt;STRONG&gt;&lt;FONT color="#0000FF"&gt; O&lt;/FONT&gt;bject&lt;/STRONG&gt; &lt;/FONT&gt;option with the title block, without the need to get its bounding box, nor to Move anything, nor to involve Osnap settings.&lt;/P&gt;</description>
      <pubDate>Wed, 23 Sep 2026 13:01:32 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14275660#M172713</guid>
      <dc:creator>Kent1Cooper</dc:creator>
      <dc:date>2026-09-23T13:01:32Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14275784#M172714</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;LI-CODE lang="general"&gt;....
(command "move" "w" (getvar "extmax") (getvar "extmin")  "" xy "0,0")
....&lt;/LI-CODE&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;But if you &lt;EM&gt;do&lt;/EM&gt; want to Move things:&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;&lt;STRONG&gt;(command "_.move" "&lt;FONT color="#FF0000"&gt;_all&lt;/FONT&gt;" "" xy "0,0")&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 23 Sep 2026 13:28:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14275784#M172714</guid>
      <dc:creator>Kent1Cooper</dc:creator>
      <dc:date>2026-09-23T13:28:19Z</dc:date>
    </item>
    <item>
      <title>Re: zoom extents in one cmd.</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14277763#M172741</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/69526"&gt;@Kent1Cooper&lt;/a&gt;&amp;nbsp;The reason I look for the title block in the move is that sometimes people leave junk in a layout for some reason so doing a move "All" would not locate the title block at a 0,0 point. This was done to match our company standard of title block has insert at 0,0. We had other programs like plot lisp's and they adhered to title block location. As well as I checked final plans and junk would be removed. Yes Zoom object is a good idea.&amp;nbsp;&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-inline" image-alt="SeaHaven_1-1790293979640.png" style="width: 400px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1662806iDAA799BC4DCFEAFC/image-size/medium?v=v2&amp;amp;px=400" role="button" title="SeaHaven_1-1790293979640.png" alt="SeaHaven_1-1790293979640.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;</description>
      <pubDate>Thu, 24 Sep 2026 23:55:43 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/zoom-extents-in-one-cmd/m-p/14277763#M172741</guid>
      <dc:creator>Sea-Haven</dc:creator>
      <dc:date>2026-09-24T23:55:43Z</dc:date>
    </item>
  </channel>
</rss>

