+ Reply to Thread
Results 1 to 3 of 3
  1. #1
    Junior Member
    Using
    AutoCAD 2011
    Join Date
    Mar 2010
    Posts
    15

    Default LISP (or other) to load custom .pgp files (acad.pgp)

    Registered forum members do not see this ad.

    AutoCAD 2008

    Hi, I am wondering if anyone knows a way to save and load (open) a .pgp file without manually navigating through the ALIAS EDITOR dialogue box. I am looking to write a LISP function that has two commands. The first command (c:loadWalton10) stores the current settings to a location on the Company Server (such as ...\TEMP.pgp) and then loads my setup from a file also stored on the server (such as ...\walton10.pgp). The second command (c:unloadWalton10) would restore the original settings (from ...\TEMP.pgp).

    I would probably add other loads to these commands as I figure them out, which is why I am looking for a LISP program to do it, since I am somewhat familiar with LISP and not at all with VBA; however, whatever language would work I would be interested to see. We use various versions of ACAD at our office, but most are 2008 or more recent.

    Thanks very much for your help.

    AutoCAD 2008

  2. #2
    Forum Deity MSasu's Avatar
    Discipline
    Construction
    MSasu's Discipline Details
    Occupation
    engineer
    Discipline
    Construction
    Details
    AutoLISP programmer
    Using
    AutoCAD 2013
    Join Date
    Mar 2009
    Location
    Brasov, Romania
    Posts
    3,942

    Default

    The REINIT command will allow to re-load the PGP file - not sure if can be called on command line mode (avoid dialog box / user interaction).

    Regards,

  3. #3
    Luminous Being alanjt's Avatar
    Using
    Civil 3D 2013
    Join Date
    Apr 2008
    Posts
    6,143

    Default

    Registered forum members do not see this ad.

    Code:
    (setvar "RE-INIT" VALUE)
    Reinitializes the digitizer, digitizer port, and acad.pgp file. The setting is stored as a bitcode using the sum of the following values:

    1 Digitizer input/output port reinitialization
    4 Digitizer reinitialization
    16 PGP file reinitialization (reload)

    To specify more than one reinitialization, enter the sum of the bitcode values. For example, enter 5 to specify both digitizer port (1) and digitizer reinitialization (4).
    eg.
    Code:
    (setvar "RE-INIT" 16)
    DropBox | finding the light...
    Seann: ...it went crazy ex-girlfriend on me...
    eric_monceaux...its pretty funny seeing two AutoCAD Gods give each other flak...

Similar Threads

  1. How to auto load LISP files?
    By azman in forum AutoLISP, Visual LISP & DCL
    Replies: 21
    Last Post: 30th Aug 2013, 02:40 pm
  2. Custom menu doesn't load automatically
    By MarcoW in forum AutoLISP, Visual LISP & DCL
    Replies: 4
    Last Post: 27th Sep 2010, 11:46 am
  3. Replies: 2
    Last Post: 23rd Jul 2008, 02:53 pm
  4. Custom font does not load correctly
    By Autodesk in forum AutoCAD RSS Feeds
    Replies: 0
    Last Post: 5th Sep 2006, 12:18 pm
  5. How do I make AutoCAD load lisp files automatically?
    By TFerg in forum AutoCAD Beginners' Area
    Replies: 2
    Last Post: 14th Apr 2006, 02:53 pm

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts