See the top rated post in this thread. Click here

Results 1 to 4 of 4

Thread: autolisp to remove cuix unknown

  1. #1
    Woo! Hoo! my 1st post
    Join Date
    2023-04
    Posts
    1
    Login to Give a bone
    0

    Default autolisp to remove cuix unknown

    im trying to search all cuix

    identify each cuix loaded

    remove unknown cuix in the users pc

    several users create a different cuix that i want to remove from each users pc

    some time they download someone elses cuix and load it in autocad but our company wants them all removed

    (defun identifycuix()
    (findfile cuix "search users pc)
    (foreach cuix unknown

    sample:
    (if (/= (menugroup "MEC2005") nil)
    (command "_MENUUNLOAD" "MEC2005")
    ); end if

    (alist "acad" "express")

    (if cuix exist keep it from alist

    (if cuix is unlknown remove it

    thank you

  2. #2
    Administrator Ed Jobe's Avatar
    Join Date
    2000-11
    Location
    Turlock, CA
    Posts
    6,486
    Login to Give a bone
    0

    Default Re: autolisp to remove cuix unknown

    You could just write a Windows bat file or PowerShell script that searches the hard drive for *.cuix files. Another method is to create a company standard profile and export it as an *.arg file. Then change the AutoCAD shortcut to specify the profile with the /P switch. Then the user interface will always be the same when they start AutoCAD. But personally, I think it's rather dictatorial to do this. Suppose a user just wants to arrange things the way they like?
    C:> ED WORKING....


    LinkedIn

  3. #3
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,817
    Login to Give a bone
    0

    Default Re: autolisp to remove cuix unknown

    Removing the CUIX file itself is not going to remove the reference from AutoCAD.

    Also, unless something has changed recently, telling AutoCAD via the startup shortcut to load an ARG file always fails if a profile by that name already exists, in which case the existing profile is simply loaded, ignoring the contents of the ARG file.

    If you really want to force certain things at startup you have to actually do those things, like set a sysvar, or set the background color, or whatever it is you want to do.


    nojortiz - I have some lisp code to do what you want, give me some time to dig it up.
    R.K. McSwain | CAD Panacea |

  4. #4
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,817
    Login to Give a bone
    1

    Default Re: autolisp to remove cuix unknown

    This may help


    ;; Grabs the menus
    (setq mg (vla-get-MenuGroups *acad-object*) mglist '())
    ;; Iterates the collection, sets "mglist" to a list of loaded menu groups
    (vlax-for x mg
    (setq mglist (cons (strcase (vla-get-name x)) mglist))
    )
    ;; releases the object
    (vlax-release-object mg)
    R.K. McSwain | CAD Panacea |

Similar Threads

  1. 2013: AutoLISP to Remove Zeros from Attribute Values
    By chris.ortloff676798 in forum AutoCAD General
    Replies: 9
    Last Post: 2014-07-21, 01:39 PM
  2. Missing pdfic.cuix pdfmacad.cuix
    By kathleen.143968 in forum AutoCAD CUI Menus
    Replies: 2
    Last Post: 2010-02-01, 10:51 PM
  3. Can't get partial CUIx Ribbon contents to show up in UI
    By Steve Johnson in forum AutoCAD CUI Menus
    Replies: 6
    Last Post: 2009-07-02, 04:05 PM
  4. CUIx In AutoCAD MEP 2010
    By gfreddog in forum AutoCAD CUI Menus
    Replies: 5
    Last Post: 2009-05-15, 02:35 PM
  5. is it possible to convert a cuix file to a cui?
    By unjust in forum AutoCAD General
    Replies: 1
    Last Post: 2009-05-12, 01:47 PM

Tags for this Thread

Posting Permissions

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