Visual LISP, AutoLISP and General Customization

Reply
Valued Contributor
mhlr
Posts: 64
Registered: ‎03-18-2008
Message 1 of 14 (419 Views)

Tile Vertical Multiple Dwgs.

419 Views, 13 Replies
06-05-2012 08:16 AM

Does anyone in the group know how to do this?:

 

I have multiple dwgs. opened but minimized so that only their small windows are line up down at the bottom of Autocad. I want to know if there is a way to call them all up to full screen, tiled vertically, at the same time with one command.

 

 

Thanks in advance.

 

M.

Distinguished Mentor
_Tharwat
Posts: 580
Registered: ‎07-02-2010
Message 2 of 14 (411 Views)

Re: Tile Vertical Multiple Dwgs.

06-05-2012 10:57 AM in reply to: mhlr

The command is already existed in the menu Window -> Tile Vertically .

____________________________________________________
Get learn and learn and practice , to become experienced guy .
Valued Contributor
mhlr
Posts: 64
Registered: ‎03-18-2008
Message 3 of 14 (395 Views)

Re: Tile Vertical Multiple Dwgs.

06-06-2012 06:08 AM in reply to: _Tharwat

When I issue that command it DOES NOT bring all of the minimized dwgs. back up to full screen, is there a variable or setting somewhere to make that happen??

Distinguished Mentor
_Tharwat
Posts: 580
Registered: ‎07-02-2010
Message 4 of 14 (392 Views)

Re: Tile Vertical Multiple Dwgs.

06-06-2012 06:14 AM in reply to: mhlr

Use this code to maximize all drawings then use the command Tile Vertically .

 

(vlax-for x (vla-get-documents (vlax-get-acad-object))
  (vla-put-windowstate x Acmax)
)

 

____________________________________________________
Get learn and learn and practice , to become experienced guy .
Valued Contributor
mhlr
Posts: 64
Registered: ‎03-18-2008
Message 5 of 14 (388 Views)

Re: Tile Vertical Multiple Dwgs.

06-06-2012 06:19 AM in reply to: _Tharwat

Forgive me in advance!! I know your trying to help!! Could you tell me how to utilize this code? I know nothing about Autolisp or any programming language!! I know what I want to do but don't know how to make it happen!!

 

Thank you

*Expert Elite*
pbejse
Posts: 2,441
Registered: ‎11-24-2009
Message 6 of 14 (385 Views)

Re: Tile Vertical Multiple Dwgs.

06-06-2012 06:24 AM in reply to: mhlr

Look into vla-put-windowstate

 

WindowState

 acWindowState enum; read-write

 acMin
  The window is minimized.
 
 acMax
  The window is maximized.
 
 acNorm
  The window is normal (neither minimized nor maximized).
 

[I'm too slow......];<-----

Distinguished Mentor
_Tharwat
Posts: 580
Registered: ‎07-02-2010
Message 7 of 14 (384 Views)

Re: Tile Vertical Multiple Dwgs.

06-06-2012 06:25 AM in reply to: mhlr

It is Ok ,

1- Open Visual lisp editor by typing vlide then a new file and save the following code in the new file to a specific location and then go back to Autocad and type in the command line AP and a dialog box would appear and after that select the file that you have just created and press load .

 

2- finally , type test to see the result .

 

(defun c:Test nil
  (vl-load-com)
  (vlax-for x (vla-get-documents (vlax-get-acad-object))
    (vla-put-windowstate x Acmax)
  )
  (princ)
)

 

____________________________________________________
Get learn and learn and practice , to become experienced guy .
Valued Contributor
mhlr
Posts: 64
Registered: ‎03-18-2008
Message 8 of 14 (375 Views)

Re: Tile Vertical Multiple Dwgs.

06-06-2012 06:55 AM in reply to: _Tharwat

Perfect. thanks so much for the help! I will try this on my lunch break & get back. I was just handed a deadline that has little time to complete from my boss!!

Valued Contributor
mhlr
Posts: 64
Registered: ‎03-18-2008
Message 9 of 14 (353 Views)

Re: Tile Vertical Multiple Dwgs.

06-07-2012 08:32 AM in reply to: mhlr

I'm sorry _Tharwat,

I loaded the code fine, AP says it loaded fine. I open multiple dwgs., minimize them, open one in the full editor & type "Test".

The Autcad screen flashes but nothing happens. I enter the command for Tile Vertical & the same dwgs. are still minimized. Does this work fine on your machine??

 

thanks again,

 

M.

Distinguished Mentor
_Tharwat
Posts: 580
Registered: ‎07-02-2010
Message 10 of 14 (349 Views)

Re: Tile Vertical Multiple Dwgs.

06-07-2012 09:11 AM in reply to: mhlr

mhlr wrote:

I'm sorry _Tharwat,

I loaded the code fine, AP says it loaded fine. I open multiple dwgs., minimize them, open one in the full editor & type "Test".

The Autcad screen flashes but nothing happens. I enter the command for Tile Vertical & the same dwgs. are still minimized. Does this work fine on your machine??

 

thanks again,

 

M.


That's really strange , it works as expected here .

 

You may have an old version of Autocad ?

____________________________________________________
Get learn and learn and practice , to become experienced guy .

You are not logged in.

Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register

Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.

Need installation help?

Start with some of our most frequented solutions to get help installing your software.

Ask the Community