Results 1 to 4 of 4

Thread: Managing Customization Files

  1. #1
    Member
    Join Date
    2012-02
    Posts
    2
    Login to Give a bone
    0

    Default Managing Customization Files

    Has anyone successfully used this ( https://www.augi.com/articles/detail...mization-files ) process lined out by Matt Worland?
    I have been trying it with no luck. I'm not sure if i copied the lisps correctly, or where i'm going wrong.
    If someone can point me in the right direction, if this has been discussed, or has it working and can share a working lisp that would be great.

  2. #2
    Certifiable AUGI Addict
    Join Date
    2001-03
    Location
    Tallahassee, FL USA
    Posts
    3,667
    Login to Give a bone
    0

    Default Re: Managing Customization Files

    That link is a broad description of customization.

    We'll need a more detailed explanation of what you're trying to do and how you tried to do it. There is a CUI forum which is probably what you're looking for at: http://forums.augi.com/forumdisplay....id=&order=desc

  3. #3
    Member
    Join Date
    2012-02
    Posts
    2
    Login to Give a bone
    0

    Default Re: Managing Customization Files

    I'm trying to figure out a way to manage acad and also allow other users to manipulate it as they please, if they please without
    screwing up acad and company settings. I want to create a company.cuix and use the company.mnl to autoload lisps to
    create the necessary ribbon buttons. I also think it would be a neat idea to have the "profile settings" from this article or the like,
    inside the .mnl file, that will set the required company paths with ease. so first off i cannot seem to get the "profile settings" that i
    copied from this article to run properly. It locks up my cad when its run. After a restart of cad i can check inside my profile settings
    it sets some things but not all. I do not know enough to check this code and wonder if someone has one that they use for this purpose
    or if the one I tried to recreate is written incorrectly. Below is what i have written from what i can see in that article.
    I have changed the pathing to what i want to use. Pathing shown below is from the article.


    ;;;
    (vl-load-com)
    ;;Profile Settings
    (setq UserCAD "C:\\Users\\matt_world\\Documents\\CAD\\")
    (setq CompanyCAD "S:\\Company\\")
    (setq strFiles (vla-get-files (vla-get-preferences (vlax-get-acad-object))))
    (if (not (vl-string-search (strcase (strcat CompanyCAD "LISP"))(strcase (vla-get-SupportPath strFiles))))
    (progn
    (setq strSupportPath (strcat (vla-get-SupportPath strFiles) ";" CompanyCAD "Lisp"))
    (vla-put-SupportPath strFiles strSupportPath)
    )
    )
    (vla-put-AutoSavePath strFiles (strcat UserCad "AutoSave"))
    (vla-put-LogFilePath strFiles (strcat UserCad "Temp"))
    (vla-put-menufile strFiles (strcat UserCad "User"))
    (vla-put-enterprisemenufile strFiles (strcat CompanyCad "acad"))
    (setvar "actrecpath" (strcat UserCad "ActionRecorder"))
    (vlax-release-object strFiles)

  4. #4
    Certifiable AUGI Addict
    Join Date
    2001-03
    Location
    Tallahassee, FL USA
    Posts
    3,667
    Login to Give a bone
    0

    Default Re: Managing Customization Files

    For Support Path code: http://forums.augi.com/showthread.ph...48#post1298948
    Start of my acad.lsp may help get you started:
    Code:
    (princ "\n\"Acad.lsp\" loading. ")
    (vl-load-com)
    (defun AddSupportPath (dir / Cpath Uname)
    ; http://forums.augi.com/showthread.php?163327-Adding-support-file-search-path-as-the-first-(LISP)&p=1298948#post1298948
    ;  (setq Cpath (getenv "ACAD") Uname (strcase (getenv "Username") T) dir (vl-string-subst Uname "%Username%" dir))
      (setq Cpath (getenv "ACAD") Uname (getenv "Username") dir (vl-string-subst Uname "%Username%" dir))
      (princ "\n\nCpath = ")(princ Cpath)
      (princ "\n\ndir = ")(princ dir)
      (princ "\n\n(vl-string-search dir Cpath) = ")(princ (vl-string-search dir Cpath))
    ;  (or (vl-string-search dir Cpath) (setenv "ACAD" (strcat Cpath ";" dir)))
      (or (vl-string-search (strcase dir) (strcase Cpath)) (setenv "ACAD" (strcat Cpath ";" dir)))
      (princ)
    )
    (AddSupportPath (strcat"D:\\Users\\" (getenv "Username") "\\AppData\\Roaming\\Autodesk\\VLisp"))
    (AddSupportPath "G:\\BeaufordT\\Autocad\\Application Data\\Customization")
    (AddSupportPath "G:\\BeaufordT\\Autocad\\Application Data\\Fonts")
    ;(AddSupportPath "G:\\BeaufordT\\Autocad\\FDOT2014.C3D\\Support\\Linetype")
    
    (defun AddTrustedPath (dir / trusted Uname)
    ; http://forums.augi.com/showthread.php?163327-Adding-support-file-search-path-as-the-first-(LISP)&p=1298948#post1298948
      (setq trusted (getvar 'trustedpaths) Uname (getenv "Username") dir (vl-string-subst Uname "%Username%" dir))
      (or (vl-string-search dir trusted) (setvar 'trustedpaths (strcat trusted ";" dir)))
      (princ)
    )
    (AddTrustedPath "D:\\Users\\%Username%\\AppData\\Roaming\\Autodesk\\C3D 2018\\enu\\Support")
    (AddTrustedPath (strcat"D:\\Users\\" (getenv "Username") "\\AppData\\Roaming\\Autodesk\\C3D 2018\\enu\\Support"))
    (AddTrustedPath (vl-filename-directory (findfile "VDOT.LSP")))
    (AddTrustedPath (strcat"D:\\Users\\" (getenv "Username") "\\AppData\\Roaming\\Autodesk\\VLisp"))
    
    (defun AddPlotStylePath (dir / PlotStylePath Uname)
    ; http://forums.augi.com/showthread.php?168357-Plotting-another-company-s-drawing&p=1322685&viewfull=1#post1322685
      (setq PlotStylePath (getenv "PrinterStyleSheetDir") Uname (getenv "Username") dir (vl-string-subst Uname "%Username%" dir))
      (or (vl-string-search dir PlotStylePath) (setenv "trustedpaths" (strcat PlotStylePath ";" dir)))
      (princ)
    )
    (AddPlotStylePath "G:\\Acad")
    (AddPlotStylePath "G:\\BeaufordT\\Autocad\\Application Data\\Plot Styles")
     (setenv "PrinterStyleSheetDir" "C:\\Users\\%Username%\\appdata\\roaming\\autodesk\\c3d 2018\\enu\\plotters\\plot styles;G:\\Acad;G:\\BeaufordT\\Autocad\\Application Data\\Plot Styles")
    
    (if(vl-string-search "enu"(vla-get-CustomIconPath (vla-get-files (vla-get-preferences (vlax-get-acad-object)))))
      (vla-put-CustomIconPath (vla-get-files (vla-get-preferences (vlax-get-acad-object))) (strcat "D:\\Users\\" (getenv "username") "\\AppData\\Roaming\\Autodesk\\C3D 2018\\enu\\Support\\Icons"))
    ) ; http://www.cadtutor.net/forum/showthread.php?69519-Adding-Folders-to-Support-File-Search-Path&p=475896&viewfull=1#post475896

Similar Threads

  1. Replies: 2
    Last Post: 2014-04-02, 07:11 PM
  2. Replies: 0
    Last Post: 2013-04-17, 04:38 AM
  3. Customization files localization
    By pouellet in forum CAD Management - General
    Replies: 4
    Last Post: 2008-11-03, 04:23 PM
  4. managing layers from imported files
    By hammacksf in forum AutoCAD LT - General
    Replies: 1
    Last Post: 2006-05-15, 07:27 PM
  5. ADT 2006 Customization Files
    By oestreichc in forum AutoCAD Customization
    Replies: 2
    Last Post: 2005-11-09, 03:25 PM

Posting Permissions

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