Author Topic: a lisp to keep my palettes in order  (Read 8079 times)

0 Members and 1 Guest are viewing this topic.

SKUI_BREAKER

  • Guest
a lisp to keep my palettes in order
« on: August 05, 2008, 09:40:20 AM »
i am thinking of making a lisp routine to keep my toll palettes in order because for some reason or nother they keep changes their position which is annoying
not even my workspace setting can keep them from where i want them i have to save 4-5 of the same workspaces and go thorugh about 3 -4 of them until they will come back to order. i have all of them anchored to the right side of the screen.
my favorite order is

properties
sheetset
tool palletes
xref
design center
calculator

ELOQUINTET

  • Guest
Re: a lisp to keep my palettes in order
« Reply #1 on: August 05, 2008, 10:03:31 AM »
just a tip, you should say what version of autocad you are using. i recommend putting this in your signature like i did so people can better assist you. i experienced this problem too but am working on an older version at the moment so can't help much. i just wondered what version you use and wanted to save you having to answer this question over and over.

Chris

  • Swamp Rat
  • Posts: 548
Re: a lisp to keep my palettes in order
« Reply #2 on: August 05, 2008, 10:09:51 AM »
I have something that I use, I am using 09 and the Layer palette can cause some serious performance issues, but I like to have it as the middle of my palettes anchored on the right of my screen so I wrote a little routine that will close my bottom palette, open the layer palette, and then open the third palette.
Code: [Select]
(defun c:la ()
  (if (= (getvar "layerdlgmode") 1)
    (progn
      (command "externalreferencesclose")
      (initdia)
      (command "layer")
      (command "externalreferences")
      )
    (progn
      (initdia)
      (command "layer")
      )
    )
) ;_ end of DEFUN
you could modify this for your use.  just issue closes to all palettes, then issue the palettes to open in the order you want them to appear.
Christopher T. Cowgill, P.E.
AEC Collection 2020 (C3D)
Win 10

SKUI_BREAKER

  • Guest
Re: a lisp to keep my palettes in order
« Reply #3 on: August 05, 2008, 11:38:51 AM »
MY FIRST TRY WAS A COMPLETE FAILURE

BUT YOU LISP WORKED FINE
EXCEPT I CAN'T SEEM TO FIGURE OUT HOW TO ISSUE THE QUICK CALC COMMAND
FROM A LISP AND GET IT NOT OPEN UP RIGHT IN THE MIDDLE OF THE SCREEN.
I HAVE IT ANCHORED TO THE RIGHT BUT AND CTRL-8 "_QUICCALC" WORKS CORRECTLY FROM COMMAND LINE BUT NOT INSIDE A LISP.

Code: [Select]
(defun c:TP ()
       (command "_externalreferencesclose")
(command "_propertiesclose")
(command "'_qcclose")
(command "'_ToolPalettesClose")
(command "'_adcclose")
(command "'_SheetSetHide")
      (initdia)
       (command "_properties")
(command "_SheetSet")
(command "'_ToolPalettes")
(command "_externalreferences")
(command "'_adcenteR")
(command "_quickcalc"))
    (progn(initdia)) ;_ end of DEFUN

ronjonp

  • Needs a day job
  • Posts: 7529
Re: a lisp to keep my palettes in order
« Reply #4 on: August 05, 2008, 11:41:59 AM »
Dude,

You really should turn the CAPS LOCK off... :evil:

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

SKUI_BREAKER

  • Guest
Re: a lisp to keep my palettes in order
« Reply #5 on: August 05, 2008, 11:43:32 AM »
i am so use to it most of the time i dont remeber to.  :?

Chris

  • Swamp Rat
  • Posts: 548
Re: a lisp to keep my palettes in order
« Reply #6 on: August 05, 2008, 02:51:48 PM »
Code: [Select]
(defun c:TP ()
       (command "_externalreferencesclose")
(command "_propertiesclose")
(command "'_qcclose")
(command "'_ToolPalettesClose")
(command "'_adcclose")
(command "'_SheetSetHide")
       (command "_properties")
(command "_SheetSet")
(command "'_ToolPalettes")
(command "_externalreferences")
(command "'_adcenteR")
(initcommandversion 2)
(command "'_quickcalc")
) ;_ end of DEFUN
Christopher T. Cowgill, P.E.
AEC Collection 2020 (C3D)
Win 10

alanjt

  • Needs a day job
  • Posts: 5352
  • Standby for witty remark...
Re: a lisp to keep my palettes in order
« Reply #7 on: August 05, 2008, 10:46:08 PM »
i am so use to it most of the time i dont remeber to.  :?
i hate that. we used to have this IT guy that would freak out if you sent your emails in caps. i would send an IT request about the data server being down, or whatever, and i would get back an immediate response telling me to stop yelling at him. our plan sets have to be in all caps, i forget to turn the caps lock off sometimes, but since it's all inner-office, it shouldn't matter. oh well.
Civil 3D 2019 ~ Windohz 7 64bit
Dropbox

SKUI_BREAKER

  • Guest
Re: a lisp to keep my palettes in order
« Reply #8 on: August 06, 2008, 10:48:47 AM »
THAts exactly what i am saying who decided that typing in allcaps is yelling, it must be in that book "BLOGGING FOR DUMMY'S" i mean truly was there an email that was passed atound when the internet first started saying that all caps is yelling, i mean if i yell at dragon speak naturally it doesn't type everything i said in all caps.  i think what is considered yelling is when you put an excalmation point in a sentence. ex.    stop!!! being so picky about capslock.   now i will probably get booted for this post, because everyone these days are so thin skinned. 

ronjonp

  • Needs a day job
  • Posts: 7529
Re: a lisp to keep my palettes in order
« Reply #9 on: August 06, 2008, 11:14:00 AM »
There were some thin skinned people here but they left  :-D. I know that you are not intentionally yelling ... all caps just bugs me  :-P

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

deegeecees

  • Guest
Re: a lisp to keep my palettes in order
« Reply #10 on: August 06, 2008, 02:58:30 PM »
Here folks, add this to your acad.dvb thisdrawing module:

Code: [Select]
Private Sub AcadDocument_BeginCommand(ByVal CommandName As String)
 If CommandName = "TEXT" Or CommandName = "DTEXT" Or _
 CommandName = "DDEDIT" Or CommandName = "MTEDIT" Or _
 CommandName = "ATTEDIT" Or CommandName = "EATTEDIT" Or _
 CommandName = "DIMLINEAR" Or CommandName = "QLEADER" Or _
 CommandName = "MTEXT" Then
 'add any other command names you want caps on for
 'be sure to add them to the endcommand section below as well
   GetKeyboardState kbArray
   kbArray.kbByte(VK_CAPITAL) = 1
   SetKeyboardState kbArray
 End If
End Sub

Private Sub AcadDocument_EndCommand(ByVal CommandName As String)
 If CommandName = "TEXT" Or CommandName = "DTEXT" Or _
 CommandName = "DDEDIT" Or CommandName = "MTEDIT" Or _
 CommandName = "ATTEDIT" Or CommandName = "EATTEDIT" Or _
 CommandName = "DIMLINEAR" Or CommandName = "QLEADER" Or _
 CommandName = "MTEXT" Then
   GetKeyboardState kbArray
   kbArray.kbByte(VK_CAPITAL) = 0
   SetKeyboardState kbArray
 End If
End Sub

...and you'll never be afflicted with the yelling disease again.

SKUI_BREAKER

  • Guest
Re: a lisp to keep my palettes in order
« Reply #11 on: August 06, 2008, 03:10:50 PM »
can it be turned off at will

i think i have a lisp that works with a reactor
problem is I can't turn the reactor off anymore like i use too.

it might also need another lisp which is called autolay 3.0
and i know that it needs a vlr-manager.fas and
another sub lisp to get things moving arch_vlr_command.lsp and capslock.lsp

i could have sworn i use to be able to turn off the reactor i know it says type autolay to toggle but it doesnt work.

oh and if you press shift while typing in autocad it will let you type in lowercase.

Code: [Select]
;|=====================================================================
Capslock.lsp complete with notes and all
For Autocad 2000x
Written by: Eric Schneider, Reno, NV
3/27/2002
cadking@aol.com
=======================================================================
This program automatically toggles the 'capslock' whenever a *text command
is encountered. Or it's supposed to anyway!
=======================================================================
This program requires VLR-Manager.fas and doslib2k.arx to be in the AutoCAD
support path for "capslock" to work (both supplied in the CapsLock.zip).
=======================================================================
Anyone is welcome to use modify this program or hack it to bits as long
as Eric Schneider, or any other names aforementioned, are not held
responsible for anything whatsoever and shall not be the subject of
vulgarities. Just leave the credits in it. Deal? Cool! Enjoy the freedom
of not having to toggle the 'capslock' key as much!
=======================================================================|;
;;;load VLISP extensions
(vl-load-com);initialize VLISP extensions

;;;load the reactor manager
(if (findfile "VLR-Manager")(member nil (atoms-family 1 '("vlr-manager" "vlr-family" "vlr-object" "vlr-object-p" "vlr-syntax")))
  (load "VLR-Manager")
)

;toggles autolay on and off
(defun c:capslock (/ funcs file)
  (setq funcs '(c:capslock cl:capslock))
  (if
    (and
      (not (vl-registry-read "HKEY_CURRENT_USER\\SOFTWARE\\AutoLay" "CapsLock"));is AutoLay turned on or off in the registry?
      (member nil (atoms-family 1 (mapcar 'vl-princ-to-string funcs)));are any AutoLay subfunctions not loaded
      (or
        (member (setq file "doslib2k.arx")(arx))
        (if (setq file (findfile file))
          (arxload file)
        )
      )
      (setq file (findfile "CapsLock.lsp"))
    )
    (progn
      (vl-registry-write "HKEY_CURRENT_USER\\SOFTWARE\\AutoLay" "CapsLock" "T");set registry for AutoLay enabled
      (load file);load "CapsLock.lsp"
    )
    (progn
      (vl-registry-delete "HKEY_CURRENT_USER\\SOFTWARE\\AutoLay" "CapsLock");set registry for AutoLay disabled
      (mapcar
       '(lambda (x)(set x nil));set all CapsLock subroutines to nil
        (vl-remove 'c:capslock funcs);except for the ones needed to re-enable AutoLay
      )
      (vlr-manager '(VLR-DWG-reactor nil '((:VLR-beginClose . cl:disable))) 1);remove reactor
      (vlr-manager '(VLR-Command-reactor nil '((:VLR-commandWillStart . capslock)(:VLR-commandEnded . capslock)(:VLR-commandCancelled . capslock))) 1);remove reactor
      (princ "\nUnloaded CapsLock.lsp")
    )
  )
  (princ)
)

;;;=======================================================================
(if (vl-registry-read "HKEY_CURRENT_USER\\SOFTWARE\\AutoLay" "CapsLock");if CapsLokc is enabled in the registry, continue loading
  (progn

(defun cl:capslock (reactor info / cmd crn);main body, togles 'capslock' key
  (setq cmd (strcase (car info))
        crn (vlr-current-reaction-name)
  )
  (if
    (or
      (wcmatch cmd "*LEADER,*QLEADER,*MTEXT,*TEXT,*DDEDIT,*ATTEDIT")
      (and
        (wcmatch cmd "DIM,DIMLINEAR,DIMALIGNED,DIMORDINATE,DIMRADIUS,DIMDIAMETER,DIMANGULAR,DIMBASELINE,DIMCONTINUE,QDIM,LEADER,QLEADER,MTEXT,TEXT,DDEDIT")
        (= (vlax-variant-value (vla-getvariable *adocobj* "dimaso")) 0)
      )
    )
    (cond
      ( (member crn '(:VLR-commandEnded :VLR-commandCancelled))
        (dos_capslock)
      )
      ( (= crn ':VLR-commandWillStart )
        (dos_capslock T)
      )
    )
  )
)

;;;======================================================================
;;;disables commandEnded reactor to avoid errors when using "new" and "open"
;;;in SDI mode. The error is merely annoying and only appears at the command
;;;line as "error: no function definition: capslock" when opening or creating
;;;a new drawing. The cause of the error is commandEnded reactor present form
;;;last dwg but LISP has not yet loaded the called function in a new or opened
;;;dwg. Furthermore, the reactor cannot be removed because it has already been
;;;activated and is waiting for the command to end. Therefore, the reactor must
;;;be rendered non-functional by changing its call to the LISP command "LIST".
(defun cl:disable (reactor info / tdat)
  (if
    (= (vlax-variant-value (vla-getvariable (vlr-data reactor) "sdi")) 1);in SDI mode?
    (vlr-reaction-set
      (car (vlr-object '(VLR-Command-reactor nil '((:VLR-commandWillStart . cl:capslock)(:VLR-commandEnded . cl:capslock)(:VLR-commandCancelled . cl:capslock)))))
      :VLR-commandEnded
      'list
    )
  );end if
);end defun

;;;======================================================================
;;;Here's where we construct the reactors to do all this cool stuff
(vlr-manager '(VLR-DWG-reactor (vla-get-activedocument (vlax-get-acad-object)) '((:VLR-beginClose . cl:disable))) 3)
(vlr-manager '(VLR-Command-reactor nil '((:VLR-commandWillStart . cl:capslock)(:VLR-commandEnded . cl:capslock)(:VLR-commandCancelled . cl:capslock))) 3)

;;;======================================================================
;;;get rid of old reactor if present. The reactor will be present, because in
;;;SDI mode, it's associated namespace is not destroyed, but has the new drawing
;;;loaded into it. At the time this file is loaded, this reactor is either not
;;;present or has been rendered useless (in SDI mode) at the closing of the last
;;;dwg and is excess loaded code bulk and should be removed. The VLR-MANAGER
;;;provides an easy means of doing this.
(vlr-manager '(VLR-Command-reactor nil '((:VLR-commandWillStart . cl:capslock)(:VLR-commandEnded . list)(:VLR-commandCancelled . cl:capslock))) 1)

;;;======================================================================
(princ "\nLoaded CapsLock.lsp\n")

  );end progn
  (princ "\nLoaded CapsLock.lsp. Type \"capslock\" to enable.")
);end if
(princ)
Code: [Select]
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;
;;;     This original Copyrighted routine has been modified...
;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

;;;controlled by arch_subroutines.lsp file

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;|
Also, be aware that returning to the previous layer with OldLayer
where OldLayer is a symbol for the layer that we are going to return to,
is often cause for an error; AutoCAD rejects that very often.

A safe way to return to the previous layer is this:
(if (/= (getvar "clayer") OldLayer)
    (vla-setvariable (vla-get-activedocument (vlax-get-acad-object))
"clayer" OldLayer)
)

Alfredo Medina
alfmedina@hotmail.com
|;

(defun ARCH_OldLayer ()
  (if (/= (getvar "clayer") OldLayer)
    (vla-setvariable (vla-get-activedocument (vlax-get-acad-object)) "clayer" OldLayer)
  )
)

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; VLR_COMMAND.lsp courtesy Peter Jamtgaard 2003

;;; Vlr Command is a function that will switch the active layer in a drawing.
;;; The reactor checks the command that is starting and if it recognizes it
;;; it will switch to a specified layer. If the layer doesn't exist it will
;;; create it with the color, linetype, and plottable setting provided.
;;; To load and run this program add the lines (load "vlr_command")(c:vlr_command)
;;; to your acaddoc.lsp or another autoloading lisp routine.

(defun VLR_COMMAND-IT () 
  (vl-load-com)
  (vlr-command-reactor nil '((:vlr-commandWillStart . startCommand))) 
  (vlr-command-reactor nil '((:vlr-commandEnded . endCommand)))
  (vlr-command-reactor nil '((:vlr-commandCancelled . cancelCommand)))
  (vlr-editor-reactor nil '((:vlr-commandwillstart . ARCH:COM1))) 
)
(princ "\n*** ------ Layer Reactor Activated. ------ ***")
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defun ARCH:COM1 (CALL CALLBACK / COMLAYLST)
;;; List of corrusponding      commands layers  color linetype     plottable
  (setq COMLAYLST
         (list (list "DIMANGULAR" "dim" 4 "continuous"  :vlax-true)
               (list "DIMBASELINE" "dim" 4 "continuous" :vlax-true)
               (list "DIMCENTER" "dim" 4 "continuous" :vlax-true)
               (list "DIMCONTINUE" "dim" 4 "continuous"  :vlax-true)
               (list "DIMDIAMETER" "dim" 4 "continuous" :vlax-true)
               (list "DIMLINEAR" "dim" 4 "continuous"  :vlax-true)
               (list "DIMORDINATE" "dim" 4 "continuous" :vlax-true)
               (list "DIMRADIUS" "dim" 4 "continuous" :vlax-true)
               (list "QDIM" "dim" 4 "continuous" :vlax-true)
(list "DIMALIGNED" "dim" 4 "continuous" :vlax-true)

               (list "LEADER" "dim" 4 "continuous" :vlax-true)
               (list "QLEADER" "dim" 4 "continuous" :vlax-true)

               (list "DTEXT" "text" 4 "continuous" :vlax-true)
               (list "MTEXT" "text" 4 "continuous" :vlax-true)
               ;;(list "TEXT" "text" 4 "continuous" :vlax-true)

               (list "POINT" "X-PNTS" 7 "continuous" :vlax-true)

               (list "XREF" "XREF" 7 "continuous" :vlax-true)
         )
  )
  (foreach
         N COMLAYLST
    (if (= (strcase (car CALLBACK)) (strcase (car N)))
      (progn
        (make_layers
          (cadr N)
          (caddr N)
          (cadddr N)
          (car (cddddr N))
        )
        (setq n1 n)
        (vla-put-activelayer
          (vla-get-activedocument
            (vlax-get-acad-object)
          )
          (vlax-ename->vla-object
            (tblobjname "LAYER" (cadr N))
          )
        )
      )
    )
  ) 
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; Make layers using activeX
(defun MAKE_LAYERS (LAY_NAM COLOR LTYPE PLOTL / LAYOBJ LAYSOBJ LTYPESOBJ)
  (setq CDWGOBJ (vla-get-activedocument
                  (vlax-get-acad-object)
                )
        LAYSOBJ (vla-get-layers CDWGOBJ)
  )
  (if (not (tblobjname "layer" LAY_NAM))
    (vl-catch-all-error-p
      (vl-catch-all-apply 'vla-add (list LAYSOBJ LAY_NAM))
    )
  )
  (setq LAYOBJ (vla-item LAYSOBJ LAY_NAM))
  (if (not (tblobjname "ltype" LTYPE))
    (progn
      (setq LTYPESOBJ (vla-get-linetypes CDWGOBJ))
      (vla-load LTYPESOBJ LTYPE (findfile "acad.lin"))
      (vlax-release-object LTYPESOBJ)
    )
  )
  (vla-put-layeron LAYOBJ :vlax-true)
  (if (/= (strcase (vla-get-name LAYOBJ)) (strcase (getvar "clayer")))
    (vla-put-freeze LAYOBJ :vlax-false)
  )
  (vla-put-lock LAYOBJ :vlax-false)
  (vla-put-color LAYOBJ COLOR)
  (vla-put-linetype LAYOBJ LTYPE)
  (vla-put-plottable LAYOBJ PLOTL) 
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;Kenny Ramage @ afralisp.com
(defun startCommand (calling-reactor
                     startcommandInfo
                     /
                     thecommandstart
                    )       
  (setq OldLayer (getvar "CLAYER")) 
  (setq OldLayern OldLayer)

  ;;(vlr-editor-reactor nil '((:vlr-commandwillstart . ARCH:COM1)))
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defun endCommand (calling-reactor
                   endcommandInfo
                   /
                   thecommandend
                  )
  (setq thecommandend (nth 0 endcommandInfo))
  (cond
    ((= thecommandend "DIMANGULAR") (ARCH_OldLayer))
    ((= thecommandend "DIMBASELINE") (ARCH_OldLayer))
    ((= thecommandend "DIMCENTER") (ARCH_OldLayer))
    ((= thecommandend "DIMCONTINUE") (ARCH_OldLayer))
    ((= thecommandend "DIMDIAMETER") (ARCH_OldLayer))
    ((= thecommandend "DIMLINEAR") (ARCH_OldLayer))
    ((= thecommandend "DIMORDINATE") (ARCH_OldLayer))
    ((= thecommandend "DIMRADIUS") (ARCH_OldLayer))
    ((= thecommandend "QDIM") (ARCH_OldLayer))
    ((= thecommandend "DIMALIGNED") (ARCH_OldLayer))
    ((= thecommandend "LEADER") (ARCH_OldLayer))
    ((= thecommandend "QLEADER") (ARCH_OldLayer))

    ((= thecommandend "DTEXT") (ARCH_OldLayer))
    ((= thecommandend "MTEXT") (ARCH_OldLayer))
    ;;((= thecommandend "TEXT") (ARCH_OldLayer))

    ((= thecommandend "POINT") (ARCH_OldLayer))

    ((= thecommandend "XREF") (ARCH_OldLayer))
  )
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defun cancelCommand (calling-reactor
                      cancelcommandInfo
                      /
                      thecommandcancel
                     )
  (setq thecommandcancel (nth 0 cancelcommandInfo))
  (cond
    ((= thecommandcancel "DIMANGULAR") (ARCH_OldLayer))
    ((= thecommandcancel "DIMBASELINE") (ARCH_OldLayer))
    ((= thecommandcancel "DIMCENTER") (ARCH_OldLayer))
    ((= thecommandcancel "DIMCONTINUE") (ARCH_OldLayer))
    ((= thecommandcancel "DIMDIAMETER") (ARCH_OldLayer))
    ((= thecommandcancel "DIMLINEAR") (ARCH_OldLayer))
    ((= thecommandcancel "DIMORDINATE") (ARCH_OldLayer))
    ((= thecommandcancel "DIMRADIUS") (ARCH_OldLayer))
    ((= thecommandcancel "QDIM") (ARCH_OldLayer))
    ((= thecommandend "DIMALIGNED") (ARCH_OldLayer))
    ((= thecommandcancel "LEADER") (ARCH_OldLayer))
    ((= thecommandcancel "QLEADER") (ARCH_OldLayer))

    ((= thecommandcancel "DTEXT") (ARCH_OldLayer))
    ((= thecommandcancel "MTEXT") (ARCH_OldLayer))
    ;;((= thecommandcancel "TEXT") (ARCH_OldLayer))

    ((= thecommandcancel "POINT") (ARCH_OldLayer))

    ((= thecommandcancel "XREF") (ARCH_OldLayer))
  )   
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(VLR_COMMAND-IT)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(princ)
« Last Edit: August 06, 2008, 03:26:27 PM by SKUI_BREAKER »

Chris

  • Swamp Rat
  • Posts: 548
Re: a lisp to keep my palettes in order
« Reply #12 on: August 06, 2008, 03:12:41 PM »
Here folks, add this to your acad.dvb thisdrawing module:

Code: [Select]
Private Sub AcadDocument_BeginCommand(ByVal CommandName As String)
 If CommandName = "TEXT" Or CommandName = "DTEXT" Or _
 CommandName = "DDEDIT" Or CommandName = "MTEDIT" Or _
 CommandName = "ATTEDIT" Or CommandName = "EATTEDIT" Or _
 CommandName = "DIMLINEAR" Or CommandName = "QLEADER" Or _
 CommandName = "MTEXT" Then
 'add any other command names you want caps on for
 'be sure to add them to the endcommand section below as well
   GetKeyboardState kbArray
   kbArray.kbByte(VK_CAPITAL) = 1
   SetKeyboardState kbArray
 End If
End Sub

Private Sub AcadDocument_EndCommand(ByVal CommandName As String)
 If CommandName = "TEXT" Or CommandName = "DTEXT" Or _
 CommandName = "DDEDIT" Or CommandName = "MTEDIT" Or _
 CommandName = "ATTEDIT" Or CommandName = "EATTEDIT" Or _
 CommandName = "DIMLINEAR" Or CommandName = "QLEADER" Or _
 CommandName = "MTEXT" Then
   GetKeyboardState kbArray
   kbArray.kbByte(VK_CAPITAL) = 0
   SetKeyboardState kbArray
 End If
End Sub

...and you'll never be afflicted with the yelling disease again.
I'm not a vba guy, could you somewhat explain how to load it, or add it?
Christopher T. Cowgill, P.E.
AEC Collection 2020 (C3D)
Win 10

deegeecees

  • Guest
Re: a lisp to keep my palettes in order
« Reply #13 on: August 06, 2008, 03:18:49 PM »
First, make sure your acad.dvb is in your support path. Find it, and put it there.

In AutoCad, Alt+F11, then double click on the ThisDrawing module at upper left, and paste the provided code to the end of the file.

Clear as mud?

Chris

  • Swamp Rat
  • Posts: 548
Re: a lisp to keep my palettes in order
« Reply #14 on: August 06, 2008, 03:25:34 PM »
First, make sure your acad.dvb is in your support path. Find it, and put it there.

In AutoCad, Alt+F11, then double click on the ThisDrawing module at upper left, and paste the provided code to the end of the file.

Clear as mud?
is acad.dvb a user created file? never mind I answered my own question, the only acad.dvb files on my computer are in the sample folder should I copy this file to my support path, or should I just create a blank file?
Christopher T. Cowgill, P.E.
AEC Collection 2020 (C3D)
Win 10

deegeecees

  • Guest
Re: a lisp to keep my palettes in order
« Reply #15 on: August 06, 2008, 03:27:32 PM »
can it be turned off at will

Its basically an I/O switch. You can still manipulate the caps lock manually if you want to.

deegeecees

  • Guest
Re: a lisp to keep my palettes in order
« Reply #16 on: August 06, 2008, 03:31:23 PM »
...should I copy this file to my support path, or should I just create a blank file?

Copy the one in the sample folder. AutoCad looks for this file every time you start up. From the looks of things, it hasn't been available through your support path, so it moves on. When you put this file in your support path, it will see it and load every time you start AutioCad.

SKUI_BREAKER

  • Guest
Re: a lisp to keep my palettes in order
« Reply #17 on: August 06, 2008, 03:35:02 PM »
oh i forgot to add the autolay lsp that makes it all possible
sorry though i cant add the vlr-manager.fas because when i open it up all i see is squares  ex.  Q   _Ò     2 Q  j

Code: [Select]
;;;load VLISP extensions
(vl-load-com);initialize VLISP extensions

;;;load the reactor manager
(if (member nil (atoms-family 1 '("vlr-manager" "vlr-family" "vlr-object" "vlr-object-p" "vlr-syntax")))
  (load "VLR-Manager")
)

;toggles autolay on and off
(defun c:autolay (/ funcs file)
  (setq funcs '(c:autolay al:autolay al:cmdbegin al:cmdcancelled al:color al:cmdend al:disable al:exist al:layerstate al:linetype al:loadtype al:lweight al:mklayer al:putinlist al:reactorload))
  (if
    (and
      (not (vl-registry-read "HKEY_CURRENT_USER\\SOFTWARE\\AutoLay" "AutoLay"));is AutoLay turned on or off in the registry?
      (member nil (atoms-family 1 (mapcar 'vl-princ-to-string funcs)));are any AutoLay subfunctions not loaded
      (setq file (findfile "AutoLay[3.0].lsp"))
    )
    (progn
      (vl-registry-write "HKEY_CURRENT_USER\\SOFTWARE\\AutoLay" "AutoLay" "T");set registry for AutoLay enabled
      (load file);load "AutoLay[3.0].lsp"
    )
    (progn
      (vl-registry-delete "HKEY_CURRENT_USER\\SOFTWARE\\AutoLay" "AutoLay");set registry for AutoLay disabled
      (mapcar
       '(lambda (x)(set x nil));set all AutoLay subroutines to nil
        (vl-remove 'c:autolay (vl-remove 'al:putinlist funcs));except for the ones needed to re-enable AutoLay
      );set AutoLay subroutines to nil
      (vlr-manager '(VLR-DWG-reactor nil '((:VLR-beginClose . al:disable))) 1);remove reactor
      (vlr-manager '(VLR-Command-reactor nil '((:VLR-commandWillStart . al:autolay)(:VLR-commandEnded . al:autolay)(:VLR-commandCancelled . al:autolay))) 1);remove reactor
      (princ "\nUnloaded AutoLay[3.0].lsp")
    )
  )
  (princ)
)

(defun al:putinlist (a d l)
  (cond
    ( (not l)(list (cons a d)));if no list, create association list in a list
    ( (not (assoc a l))(cons (cons a d) l));if no association in list, create one
    ( (subst (cons a d)(assoc a l) l));if association in list, replace it
  )
)

(if (vl-registry-read "HKEY_CURRENT_USER\\SOFTWARE\\AutoLay" "AutoLay");if AutoLay is enabled in the registry, continue loading
  (progn

(defun al:autolay (reactor info / cmd crn dat)
  (setq cmd (car info);get command
        crn (vlr-current-reaction-name);get the name of the reactor calling this function
        dat (vlr-data reactor);get data list from reactor object
  )
  (cond
    ( (and
        (= crn ':VLR-commandWillStart);is command starting?
        (not (assoc 'COMMAND dat));has a association to 'COMMAND been assiged to the reactor data to eliminate problems with transparent commands?
      )
      (vlr-data-set reactor (al:putinlist 'COMMAND cmd dat));assign an association to 'COMMAND to the reactor data list
      (al:cmdbegin reactor info);call the layer manipulating routine
    )
    ( (and
        (= crn ':VLR-commandEnded);is command ending?
        (equal cmd (cdr (assoc 'COMMAND dat)));is the association to 'COMMAND assiged to the reactor data equal to the command that filed the reactor?
      )
      (vlr-data-set reactor (vl-remove (assoc 'COMMAND dat) dat));Remove association to 'COMMAND in reactor data list
      (al:cmdend reactor info);restore previous layer status
    )
    ( (and
        (= crn ':VLR-commandCancelled);was command cancelled?
        (equal cmd (cdr (assoc 'COMMAND dat)));is the association to 'COMMAND assiged to the reactor data equal to the command that filed the reactor?
      )
      (vlr-data-set reactor (vl-remove (assoc 'COMMAND dat) dat));Remove association to 'COMMAND in reactor data list
      (al:cmdcancelled reactor info);restore previous layer status and remove new layer if one was created
    )
  )
)

;;;tests the command name, textsize, dimtext size etc.
;;;to determine if action needs to be taken. This is where the layer name
;;;comes from and where the conditions under which to act under are set up.
(defun al:cmdbegin (reactor info / ado cmd dat dsc dst dtx tst tsz)
  (setq cmd (car info);get the command
        dat (vlr-data reactor);get reactor data
        ado (cdr (assoc 'ado dat));get pointer to activeDocument
        dsc (vlax-variant-value (vla-getvariable ado "dimscale"));get scale
        dst (strcase (vla-get-name (vla-get-activedimstyle ado)));get dimstyle
        dtx (vlax-variant-value (vla-getvariable ado "dimtxt"));get dimtxt size
        tst (strcase (vla-get-name (vla-get-activetextstyle ado)));get textstyle
        tsz (vlax-variant-value (vla-getvariable ado "textsize"));get text size
  );end setq
  (cond
    ( (wcmatch cmd "HATCH,BHATCH");is the command "hatch"?
      (al:layerstate reactor info "Hatch");make, thaw, turn on and make current "Hatch" layer as needed
    );end cond 1
    ( (wcmatch cmd "VPORTS");is the command "vports"?
      (al:layerstate reactor info "Viewport");make, thaw, turn on and make current "Viewport" layer as needed
    );end cond 2
    ( (wcmatch cmd "DIM,BREAKLINE,DIMLINEAR,DIMALIGNED,DIMORDINATE,DIMRADIUS,DIMDIAMETER,DIMANGULAR,DIMBASELINE,DIMCONTINUE,QDIM,LEADER,QLEADER");are you creating a dimension?
      (al:layerstate reactor info "Dim2");make, thaw, turn on and make current "Dim" layer as needed
    );end cond 3
    ( (wcmatch cmd "DIMCENTER");are you creating a center mark?
      (al:layerstate reactor info "Center");make, thaw, turn on and make current "Dim" layer as needed
    );end cond 4
    ( (wcmatch cmd "DTEXT,MTEXT,TEXT");are you creating text?
      (al:layerstate reactor info "Text");make, thaw, turn on and make current "Text" layer as needed
    );end cond 5
  );end cond
);end defun

;;;figures out what action needs to be taken by checking
;;;the state of the layer "name" and the command being used
(defun al:layerstate (reactor info name / clo cmd lso lyo lon frz lck lof lyr)
  (setq cmd (car info);get command
        dat (vlr-data reactor);get reactor data
        ado (cdr (assoc 'ado dat));get pointer to activeDocument object
        clo (vla-get-ActiveLayer ado);get the clayer object
        lso (cdr (assoc 'lso dat));get pointer to layers object
        lyo (al:exist lso name);get the layer object for "name"
  );end setq
  (if lyo;does layer not exist?
    (progn
      (if (= (vla-get-LayerOn lyo) :vlax-false);is layer off?
        (progn
          (vla-put-LayerOn lyo :vlax-true);turn it on
          (setq lon (list 'vla-put-layeron lyo :vlax-false));save an expression to turn off later via al:cmdend
        );end progn
      );end if
      (if (= (vla-get-Freeze lyo) :vlax-true);is layer frozen?
        (progn
          (vla-put-Freeze lyo :vlax-false);thaw it
          (setq frz (list 'vla-put-freeze lyo :vlax-true));save an expression to refreeze later via al:cmdend
        );end progn
      );end if
      (if (= (vla-get-Lock lyo) :vlax-true);is layer locked?
        (progn
          (vla-put-Lock lyo :vlax-false);unlock it
          (setq lok (list 'vla-put-lock lyo :vlax-true));save an expression to lock it again later via al:cmdend
        );end progn
      );end if
    );end progn
    (setq lyo (al:mklayer reactor info name);make it
          dat (al:putinlist 'NLR lyo dat);add to data list to be stored in reactor object incase of commandCancelled event
    )
  );end if
  (if
    (and
      (wcmatch cmd "BHATCH,HATCH,BREAKLINE,DIMLINEAR,DIMALIGNED,DIMORDINATE,DIMRADIUS,DIMDIAMETER,DIMANGULAR,DIMBASELINE,DIMCONTINUE,QDIM,LEADER,QLEADER");is the command is "*hatch"*
      (setq lof (if (wcmatch cmd "BHATCH,HATCH")(al:exist lso "Hidden")(al:exist lso "Hatch")));sets the value of LOF to the hidden layer object or nil depending on the results of al:exist
      (= (vla-get-LayerOn lof) :vlax-true);on
      (= (vla-get-Freeze lof) :vlax-false);thawed
    );end and
    (progn
      (vla-put-LayerOn lof :vlax-false);turn "hidden" layer off
      (setq lof (list 'vla-put-layeron lof :vlax-true));add to data list to be stored in reactor object for commandEnded or commandCancelled event
    );end progn
  );end if
  (if (not (equal clo lyo));if layer is not current
    (progn
      (vla-put-ActiveLayer ado lyo);sets layer current
      (setq lyr (list 'vla-put-activelayer ado clo));add to data list to be stored in reactor object for commandEnded or commandCancelled event
    )
  );end if
  (setq dat (al:putinlist 'LAYDAT (vl-remove nil (list lyr lon lof frz lok)) dat));compile data
  (vlr-data-set reactor dat);commit data to reactor object
);end defun

;;;======================================================================
;;;creates layer, sets properties and returns layer object
(defun al:mkLayer (reactor info name / ado dat lso lyo color lineType lineWeight val)
  (setq dat       (vlr-data reactor)
        ado       (cdr (assoc 'ado dat))
        lso       (cdr (assoc 'lso dat))
        lyo       (vla-add lso name);create the layer
        name      (strcase name);set "name" to all capitols
        color     (al:color name);get color
        lineType  (vla-get-name
                    (al:loadLinetype reactor info
                      (al:ltype name);get linetype
                      (if (= (vlax-variant-value (vla-getvariable ado "measureinit")) 0);English or metric
                        "acad.lin"; load linetype from English linetype file
                        "acadiso.lin"; load linetype from metric linetype file
                      );end if
                    );end al:loadlinetype
                  );end vla-get-name
       lineWeight (al:lweight name)
  );end setq
  (if lyo; if the layer was made, (lyo not nil)
    (foreach prop '(color lineType lineWeight);loop therugh properties
      (if (setq val (eval prop))
        (vlax-put-property lyo prop val);set the properties for layer "name"
      );end if
    );end foreach
  );end if
  lyo; return layer object to calling function
);end defun

;;;attempts to load linetype if not loaded
;;;returns linetype object name if loaded else nil
(defun al:loadlinetype (reactor info name fname / dat linetypes)
  (setq dat (vlr-data reactor)
        linetypes (cdr (assoc 'linetypes dat))
  )
  (if (not (al:exist linetypes name));linetype is not loaded
    (vl-catch-all-apply
       'vla-load (list linetypes name fname);load it, unfortunately vla-load returns nil on success or error on fail instead of linetype object
    );trap error if load fails
  );end if
  (al:exist linetypes name);return linetype object if exists, else nil
);end defun

;;;returns ActiveX object if exist, else nil
(defun al:exist (collection item / rslt)
  (if
    (not
      (vl-catch-all-error-p
        (setq rslt
          (vl-catch-all-apply 'vla-item
            (list collection item)
          );trap error
        );end setq
      );return T if successful, else nil
    );end not
    rslt; return object or nil
  );end if
);end defun

;;;======================================================================
;;;returns lineTypeName according to layer standard for "name"
;;;edit linetypes according to your layer standard
(defun al:ltype (name)
  (cond
    ((wcmatch name "BREAK") "phantom");break layer, phantom linetype
    ((wcmatch name "CENTER") "center2");center layer, center2 linetype
    ((wcmatch name "HIDDEN") "hidden");hidden layer, hidden linetype
    (T "continuous");if "name" not found return "continuous" linetype
  );end cond
);end defun

;;;returns lineweight (enumerated, metric equivelant) according to layer "name"
;;;edit lineweights according to your layer standard
;;;valid values are:
;;;acLnWtByBlock, acLnWtByLwDefault,
;;;acLnWt000, acLnWt005, acLnWt009, acLnWt013
;;;acLnWt015, acLnWt018, acLnWt020, acLnWt025
;;;acLnWt030, acLnWt035, acLnWt040, acLnWt050
;;;acLnWt053, acLnWt060, acLnWt070, acLnWt080
;;;acLnWt090, acLnWt100, acLnWt106, acLnWt120
;;;acLnWt140, acLnWt158, acLnWt200, acLnWt211
(defun al:lweight (name / color)
  (cond
    ((wcmatch name "CENTER,DIM") acLnWt020);red, 0.008"
    ((wcmatch name "TEXT") acLnWt015);blue, 0.006"
    ((wcmatch name "HATCH,HIDDEN") acLnWt009);magenta, 0.004"
    ((wcmatch name "VIEWPORT") acLnWt053);white, 0.021"
    (T acLnWtByLwDefault);if "color" not found return default lineweight
  );end cond
);end defun

;;;returns color (intiger) for layer "name"
;;;edit colors according to your layer standard
(defun al:color (name)
  (cond
    ((wcmatch name "CENTER,DIM") 1)
    ((wcmatch name "DIM2,OBJECT_MEDIUM,PIPE,TEXT,TITLE") 5)
    ((wcmatch name "HATCH,HIDDEN") 6)
    ((wcmatch name "Viewport") 7)
    (T (acad_colordlg 1 nil));if "name" not found bring up color dialog
  );end cond
);end defun

;;;======================================================================
;;;upon completion of command restores lso to previous state
(defun al:cmdend (reactor info / dat ldt)
  (setq dat (vlr-data reactor);get reactor data
        ldt (assoc 'LAYDAT dat);get saved expressions to restore layer
        dat (vl-remove ldt dat);remove LDT from data list
  )
  (mapcar 'eval (cdr ldt));evaluate elements of LDT
  (vlr-data-set reactor dat);commit data to reactor object
)

;;;======================================================================
(defun al:cmdcancelled (reactor info / dat nlr)
  (setq dat (vlr-data reactor);get reactor data
        nlr (assoc 'NLR dat);get pointer to newly created layer
        dat (vl-remove nlr dat);remove NLR from data list
  )
  (al:cmdend reactor info);restore previous layer state
  (if nlr (vla-delete (cdr nlr)));delete newly created layer if any
  (vlr-data-set reactor dat);commit data to reactor object
)

;;;======================================================================
;;;disables commandEnded reactor to avoid errors when using "new" and "open"
;;;in SDI mode. The error is merely annoying and only appears at the command
;;;line as "error: no function definition: al:restore" when opening or creating
;;;a new drawing. The cause of the error is commandEnded reactor present form
;;;last dwg but LISP has not yet loaded the called function in a new or opened
;;;dwg. Furthermore, the reactor cannot be removed because it has already been
;;;activated and is waiting for the command to end. Therefore, the reactor must
;;;be rendered non-functional by changing its call to the LISP command "LIST".
(defun al:disable (reactor info)
  (if (= (vlax-variant-value (vla-getvariable (vlr-data reactor) "sdi")) 1);in SDI mode?
    (vlr-reaction-set
      (car (vlr-object '(VLR-Command-reactor nil '((:VLR-commandWillStart . al:autolay)(:VLR-commandEnded . al:autolay)(:VLR-commandCancelled . al:autolay)))))
      :VLR-commandEnded
      'list;the only function I could find that would work without errors
    )
  );end if
);end defun

;;;======================================================================
;;;Here's where we construct the reactors to do all this cool stuff
(defun al:reactorload (/ ado dat)
  (setq ado (vla-get-ActiveDocument (vlax-get-acad-object));get pointer to activeDocument
        dat     (list;create a list of associations to pointers for use during the entire drawing session
  (cons 'ado ado);store pointer to activeDocument
                  (cons 'lso (vla-get-layers ado));get and store pointer to layers collection
                  (cons 'linetypes (vla-get-linetypes ado));get and store pointer to linetypes collection
                );end list
  );end setq
  (vlr-manager '(VLR-DWG-reactor ado '((:VLR-beginClose . al:disable))) 3);construct reactor to call 'al:disable' on beginClose event
  (vlr-manager '(VLR-Command-reactor dat '((:VLR-commandWillStart . al:autolay)(:VLR-commandEnded . al:autolay)(:VLR-commandCancelled . al:autolay))) 3);construct reactor to call 'al:cmdbegin' on commandWillStart commandEnded and commandCancelled events
)
(al:reactorload);excecute reactor construction

;;;======================================================================
;;;get rid of old reactor if present. The reactor will be present, because in
;;;SDI mode, it's associated namespace is not destroyed, but has the new drawing
;;;loaded into it. At the time this file is loaded, this reactor is either not
;;;present or has been rendered useless (in SDI mode) at the closing of the last
;;;dwg and is excess loaded code bulk and should be removed. The VLR-MANAGER
;;;provides an easy means of doing this.
(vlr-manager '(VLR-Command-reactor nil '((:VLR-commandWillStart . al:autolay)(:VLR-commandEnded . list)(:VLR-commandCancelled . al:autolay))) 1)

;;;======================================================================
(princ "\nLoaded AutoLay[3.0].lsp\n")

  );end progn
  (princ "\nLoaded AutoLay[3.0].lsp. Type \"autolay\" to enable.")
);end if
(princ)

Chris

  • Swamp Rat
  • Posts: 548
Re: a lisp to keep my palettes in order
« Reply #18 on: August 06, 2008, 03:35:18 PM »
...should I copy this file to my support path, or should I just create a blank file?

Copy the one in the sample folder. AutoCad looks for this file every time you start up. From the looks of things, it hasn't been available through your support path, so it moves on. When you put this file in your support path, it will see it and load every time you start AutioCad.
i get a compile error, variable has not been defined
I believe it is referring to kbArray
Christopher T. Cowgill, P.E.
AEC Collection 2020 (C3D)
Win 10

SKUI_BREAKER

  • Guest
Re: a lisp to keep my palettes in order
« Reply #19 on: August 06, 2008, 03:38:34 PM »
mine is very easy if you already have the vlr-manager file "or at lest i think its required"
all you do is save all thre of the lisp in seperate files then load then in to autocad.

Chris

  • Swamp Rat
  • Posts: 548
Re: a lisp to keep my palettes in order
« Reply #20 on: August 06, 2008, 03:42:26 PM »
mine is very easy if you already have the vlr-manager file "or at lest i think its required"
all you do is save all thre of the lisp in seperate files then load then in to autocad.
yes, but it also says it requires doslib, and we dont have that installed.
Christopher T. Cowgill, P.E.
AEC Collection 2020 (C3D)
Win 10

deegeecees

  • Guest
Re: a lisp to keep my palettes in order
« Reply #21 on: August 06, 2008, 03:48:47 PM »
...should I copy this file to my support path, or should I just create a blank file?

Copy the one in the sample folder. AutoCad looks for this file every time you start up. From the looks of things, it hasn't been available through your support path, so it moves on. When you put this file in your support path, it will see it and load every time you start AutioCad.
i get a compile error, variable has not been defined
I believe it is referring to kbArray

*forhead smack*

Aww geez, I forgot, you'll need to add this to the top of the file. Sorry folks, the old noggin slips up more so lately than ever.

Code: [Select]
Option Explicit
Private Const VK_CAPITAL = &H14

Private Type KeyboardBytes
    kbByte(0 To 255) As Byte
End Type

Private kbArray As KeyboardBytes

Private Declare Function GetKeyState Lib "user32" _
  (ByVal nVirtKey As Long) As Long

Private Declare Function GetKeyboardState Lib "user32" _
  (kbArray As KeyboardBytes) As Long

Private Declare Function SetKeyboardState Lib "user32" _
  (kbArray As KeyboardBytes) As Long
Private Declare Function GetForegroundWindow Lib "user32" () As Long

SKUI_BREAKER

  • Guest
Re: a lisp to keep my palettes in order
« Reply #22 on: August 06, 2008, 03:51:09 PM »
a doslib i have no idea what that is

i do know that i have taken it to a few computers pasted it on hard drive and then added the 2 lisp and the vlr-manager.fas to autocad startup
and i was done of course they all had windows XP.

deegeecees

  • Guest
Re: a lisp to keep my palettes in order
« Reply #23 on: August 06, 2008, 03:54:43 PM »
a doslib i have no idea what that is

Some helpful info for you:

http://www.en.na.mcneel.com/doslib.htm

Chris

  • Swamp Rat
  • Posts: 548
Re: a lisp to keep my palettes in order
« Reply #24 on: August 06, 2008, 03:56:46 PM »
a doslib i have no idea what that is

Some helpful info for you:

http://www.en.na.mcneel.com/doslib.htm
now how do I get it to load automatically, it seems I have to hit alt+f11  for the program to start working
Christopher T. Cowgill, P.E.
AEC Collection 2020 (C3D)
Win 10

SKUI_BREAKER

  • Guest
Re: a lisp to keep my palettes in order
« Reply #25 on: August 06, 2008, 03:58:42 PM »
i dont remember ever loading the doslib.exe but i have it now
and i also found this link to all the files i have talked about before.
every file that is needed is here including capslock.lsp

http://discussion.autodesk.com/servlet/JiveServlet/download/126-320799-2665920-26512/AutoLay[3.0].zip

deegeecees

  • Guest
Re: a lisp to keep my palettes in order
« Reply #26 on: August 06, 2008, 04:01:40 PM »
a doslib i have no idea what that is

Some helpful info for you:

http://www.en.na.mcneel.com/doslib.htm
now how do I get it to load automatically, it seems I have to hit alt+f11  for the program to start working

If acad.dvb is in your support path structure, then all you have to do is start typing some DTEXT, or MTEXT, etc.

Chris

  • Swamp Rat
  • Posts: 548
Re: a lisp to keep my palettes in order
« Reply #27 on: August 06, 2008, 04:09:44 PM »
for some reason it doesnt work, I am going to look into the doslib,  I kind of have an issue with vba as it is being phased out.  it should be pretty easy to have the arx autoload using our exisitng setup and I'll just add an additional reactor to fire and run the capslock on and off toggle.  all the other programming seems to be overkill, it will take at most 5 lines of code to run the capslock toggle, base on the newer doslib help.
Christopher T. Cowgill, P.E.
AEC Collection 2020 (C3D)
Win 10

deegeecees

  • Guest
Re: a lisp to keep my palettes in order
« Reply #28 on: August 06, 2008, 04:20:54 PM »
If you're networked, then your Cad Manager must have a different copy of acad.dvb somewhere, so I woudn't mess with it.

Chris

  • Swamp Rat
  • Posts: 548
Re: a lisp to keep my palettes in order
« Reply #29 on: August 07, 2008, 08:16:39 AM »
If you're networked, then your Cad Manager must have a different copy of acad.dvb somewhere, so I woudn't mess with it.
we are networked, and I am the CAD Manager, but I am not that worried, I was really only going to set it up for me,  Controlling that is a little easier with a lisp routine.
Christopher T. Cowgill, P.E.
AEC Collection 2020 (C3D)
Win 10

deegeecees

  • Guest
Re: a lisp to keep my palettes in order
« Reply #30 on: August 07, 2008, 09:46:25 AM »
Controlling that is a little easier with a lisp routine.

If you say so...   :lol: