AutoCAD Visual LISP / AutoLISP :: Deployment Of Registry-Saved System Variables

Jun 10, 2013

My company is in the process of upgrading to AutoCAD 2013 (yes, I know 2014 is out, but IT won’t let us get the most recent because of fear of “new release bugs”). My company is small and our CAD Standards/Management is less than desirable. Over the past few years I have become the unofficial company CAD Manager and have slowly been getting us up to speed with using the latest capabilities and following best practices.

An issue that I deal with constantly is a new user not having the correct registry-saved system variables set up. This also happens a lot because our IT guy frequently reinstalls AutoCAD to fix issues. Every time AutoCAD is installed/reinstalled, all the registry-saved system variables are set to their default values. We have several that need to be set a certain way to match our current drafting standards (a few examples: .bak files turned off, plot.log files turned off, advanced attribute editor turned on, plot area relative to edge of paper, etc, etc.). Typically, I will get complaints from users about something not working correctly, and then I will troubleshoot the issue and eventually find out that they just had their AutoCAD reinstalled and their system variables are not set how they should be. Then I will get out my list and have them set all the variable s properly via the AutoCAD command line.

 I have read up on creating AutoCAD Deployments (and we will be using these Deployments for this upgrade), but there does not seem to be a way to set variables when creating the Deployment.

Finally, to complicate things a little more, most of our users actually use AutoCAD LT (so no Lisp), and only a select few (like me) have full AutoCAD. So, we will be creating two separate Deployment files as it stands (which is not a big deal).

Some of my preferred criteria for the solution:

-Solution can be used for both AutoCAD & AutoCAD LT (I’m okay with there being two separate system variable “deployment” files since we will already have two different AutoCAD Deployments. I would just like the procedure for deploying both packages to be the same regardless of whether it’s for LT or full version).

- Solution would be able to be applied to each workstation without opening AutoCAD on each machine (and ideally, it would all happen when the AutoCAD Deployment installer was run!)

Is there any current best practices for accomplishing this? (maybe by changing the registry through batch files, VBscript files, etc? Or using AutoCAD script files – however, this requires the program to be open to run, which I was trying to avoid).

View 7 Replies


ADVERTISEMENT

AutoCAD Visual LISP / AutoLISP :: Setting System Variables

Feb 23, 2012

a simple lisp file?

I want to set "hideprecision" to 1. This variable can not be saved - I looked it up in Express Tools.

So I thought a lisp file to load at start up would do the trick.

View 3 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Reset All System Variables?

Oct 11, 2012

How I can reset all system variables. I refer to the variables that affect the program globally. I want all remain at the default value. One lisp?

View 2 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Include 360 In Deployment Without Restart Message?

May 28, 2013

I'm trying to include the Autodesk 360 SP1 in my 2014 deployment.  Its working fine but it prompts for a restart and I'd rather not require user action to complete the install. (the users here restart frequently enough to deal with this anyway)

I have tried the following switches in the parameters section to no avail:

/s /qn
/s /v/qn
/s qn "REBOOT = ReallySupress"
/s /v/qn "REBOOT = ReallySupress"

View 1 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Create ONLY Custom Shortcut During Deployment?

May 28, 2013

I'm creating a deployment for AutoCAD 2014.

At the end of the deploy process I'd like to end up with a custom AutoCAD shortcut on the desktop that calls an ARG file.  This is no problem.

The problem is that to get that shortcut I need to check the "create desktop shortcut" check box and then I wind up with 2 shortcuts on the desktop, the default "AutoCAD 2014 - English" and my custom shortcut.

View 3 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Get Registry Key Value And Process It

Dec 12, 2012

I would like to capture a registry key value using autolisp if the value of they key equals TEXTEXAMPLE then exit Autocad else nothing.

View 4 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Add / Modify And Remove Registry Key?

Feb 27, 2012

Some time ago I was able to add modyfy and remove regestry keys ussing AutoLISP Unfortunatly I have lost the information on how to do this.

View 1 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Change Profile Through Registry Settings

Jun 26, 2012

I'm trying to fix my profile via lisp-registry key. Why? Because the profile we use is part of a plug-in meaning we can do it using our profile so I alternatively the answer is to tweak the one supplied as part of the plug in.

The method I’m familiar with is to edit using the following code as example;

 (vl-registry-write "HKEY_CLASSES_ROOT\.PEN\Shell\open\command" "" "notepad.exe %1")
 
However that’s for creating a new registry key entry the one I have already exists but needs to be modified, better yet the profiles name (*.arg file) can change with updates, so in my search I came across the following link.
 
[URL] 

Now I cant put it together and am not sure where I have gone wrong…(See code bellow)
 
(vl-registry-write "hkcu "\Profiles\" (getvar 'cprofile) "\General\DefaultConfig" "\\DCMAR02\A03P20")

View 1 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Can't Append Registry To Value Of SAVEFILEPATH Variable

Oct 2, 2012

How come I can't modify the following registry key to the SAVEFILEPATH variable?
 
(vl-registry-write "HKEY_CLASSES_ROOT\SOFTWARE\Treadstone\File Sweeper" "NETWORK_LOCATION" SAVEFILEPATH)

View 1 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Registry Key For Current Profile (cprofile)

May 30, 2013

Which registry Key stores the name of the Current profile ("cprofile")?
I tried following, all reurn 'nil'

(vl-registry-read "HKEY_CURRENT_USER\Software\Autodesk\AutoCADR18.1\ACAD-9005:409\Profiles")

(vl-registry-read
"HKEY_CURRENT_USER\Software\Autodesk\AutoCADR18.1\ACAD-9005:409\Profiles\(default)")

In the registry when I double-click the key, the value is displayed. But I can't access it.

View 2 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Dotted Pairs With Variables?

Apr 2, 2012

So what I'm trying to do is make a selection set that will only select a specific dimension, as I don't know the exact placement as it varies depending on the size of the part. I know what the value will be, but again the value depends on the size of the part, but one of the items earlier in my program is I get the Hole Spacing, which the dimension I need to select is Half of the Hole Spacing. Here is what I'm trying:

(setq HALFBOLTSPCDXF '((1 . HALFBOLTSPC)))
 where HALFBOLTSPC is a variable that takes the Bolt Spacing and divides it by 2.

When I do a run selection in Visual LISP, I get the following:

((1 . HALFBOLTSPC))

 But what I was expecting to get was:

((1 . "10.00""))

 As my test case is using 20" Hole Spacing which means half the hole spacing is 10.00". So is there another way to do this? OR what do I need to do to get it to recognize the Variable and give the value instead of the Variable name?

If needed: AutoCAD 2013 User using Visual LISP for editing LISP and DCL files Also I have AutoCAD 2011 currently still available for us, but we are using AutoCAD 2013 for 99.9% of AutoCAD use

View 6 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Reading Some Variables Into DWG File?

Jun 5, 2013

How can I read the content/ string in the *.dwg file through autolisp?

Suppose I have used any word multiple times in a sheet. How can I count it through lisp programme?

View 9 Replies View Related

AutoCAD Visual LISP / AutoLISP :: How To Assign Value To List Of Variables

Oct 31, 2013

I am unsure why my Lisp does not work.

(DEFUN C:Clear_values (/ GLBLS) (SETQGLBLS '(*DATEDRAWN* *DRAFTNAME* *JOBNUMBER* *OWNERNAME**JOBCOE* *PERMITREVDATE* *PERMITCONTACT* *HOMEBUILDER**SUBDIVISION* *ADDRESS**CITY* *STATE* *ZIP* *LOT#**PARCEL#* *NSCOORD* *EWCOORD* *STANDARDDETAIL#**SUPERNAME* *SALESMAN**GATECODE* *HOMEPHONE* *WORKPHONE* *ALTPHONE1**ALTPHONE2* *EMAIL1* *EMAIL2* *ACCESS**EXCAVATIONTYP* *EXCATDEMO1**EXCATDEMO2* *SKIMRUN* *AWLRUN*

[code]....

 I've tried several options such as (mapcar 'set GLBLS "%%") but nothing happens, and with the above code nothing happens; the code only returns nil.

View 8 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Deleting Recent Documents From Registry (DST Files)

Dec 30, 2013

I downloaded a Copy of AutoCAD Recent Documents Manager.exe from the autodesk website and it won't run on any of the computers in our system. I was thinking about writing a LISP routine to delete the filenames with a DST suffix by replacing them with the next filename in the list. My question is If I replace the file with the next one above and the filetime,filepinned and class respectively. When I reach the end of the list can I just use "" for the file,filetime and class and integer 0 for filepinned (it looks like it requires a double).

View 1 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Passing Variables To Command Line?

Aug 14, 2012

Writing a routine that stores a file name as a string in variable FILE.I check the variable and it returns a nice quoted string: "filename-123.dwg"

I would like AutoCAD to open the file w/out user input.With FILEDIA set to 0, I've tried passing the variable to the command line:

(command "open" FILE)

or in a script as:

open

(FILE)
...

or,

open

!FILE
...

I get the same error. The string dumps to the command line and I get 'Unknown command "DWG" .'

View 9 Replies View Related

AutoCAD Visual LISP / AutoLISP :: How To Create Princ That Displays Variables Value

Jan 11, 2012

I have a custom variable id like to have displayed in my princ section I have the following however it keeps returning ; error: bad argument type: file 
 
(princ MYVAR " file found..."))

How  can I fix this?

View 1 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Write Content Of Variables To Text File?

Feb 17, 2013

I want to write content of variables to a text file but I should have conversion function for variables.

for example

(setq a 123); a is an integer type, contetnt of a is 123

so I should use (itoa a) to get "123" as a string and then I can write it to text file.

but what about another type of variables?
 
(defun ToString ( a / result)(setq result "")(cond((= (type a) 'ENAME) (progn (setq result "Entity names")))((= (type a) 'EXRXSUBR) (progn (setq result "External ObjectARX applications")))((= (type a) 'FILE) (progn (setq result "File descriptors")))((= (type a) 'INT) (progn (setq result (itoa

[Code].....

View 5 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Grab All Text In Drawing - Incrementing Variables

Aug 1, 2013

I have this lisp that grabs all the text(the value and the location) in my drawings and I put them into a list.  Here is what I have so far:

(defun c:loop ()
(setq numbers (ssget "_X" (list (cons 0 "TEXT") (cons 1 "##*")) ))
(setq newlist '())
(setq IN 0);set index
(setq SLGTH (sslength numbers))
[code].......   

What i need to happen is this:  When "whatever" returns "value0" i need to set "value0" to the first item in list "newlist".  Then when "whatever" returns "value1" i need to set "value1" to the second item.  Now I can do it the long hand way, but i am trying to simplify this step, and shorten up my overall program.

View 4 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Extracting Attribute Values And Assigning To Variables?

May 27, 2013

How can specific attribute values be extracted from a drawing and assigned to a variable in lisp. 

The existing title block is having attributes : Area, Sub area, Description, Drawing type. I want to extract this values and assign it to some variable which I have already listed and then it shall be assigned to some other attributes in the same drawing with Area1, Subarea1, Description1, Drawing type1... and so on.. Both the attributes shall be in the same drawing file.

View 3 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Show (read / Assign Variables) To Normal Or Custom Properties In Object?

Apr 9, 2012

Looking for Lisp command to show (read/assign variables) to normal or custom properties in an object?

View 7 Replies View Related

AutoCAD Visual LISP / AutoLISP :: MODEMACRO Saved Xx Mins Ago

Dec 10, 2013

I have the following line in my acaddoc.lsp:

(SETVAR "MODEMACRO"
"$(Getvar,LOGINNAME) last saved $((* 1440 (substr,$(getvar,date), $(getvar,tdupdate)))) mins ago")

You can probably see what I'm trying to do.The LOGINNAME part works fine, but the time doesn't.  The goal is to constantly display the elapsed time since the last save, formatted in minutes. The function is not working; here's what I get in my status bar:  

I'm a novice at lisp and diesel, but I thought I could get this one.I also tried this way:

Command: (setq mydate (getvar "date"))
2.45664e+006

Command: (setq savedate (getvar "tdupdate"))
2.45664e+006

Command: (setq minsincesave (* 1440 (- mydate savedate)))
34.7048

This actually worked, in a way.  I could call the setq "minsincesave" in a mtext field "LispVariable", and I probably could put in in a modemacro too (didn't try).  But the problem here is that "mydate" and "savedate" (and "minsincesave") are not automatically updated.  I had mtext with the field displaying "minsincesave", and it won't update unless you run all the (setq ....) again for each variable.  I guess I understand: the setq is set, and it doesn't change even if the variable does change.

View 7 Replies View Related

AutoCAD Visual LISP / AutoLISP :: How To Check If System Variable Is Read Only

Nov 22, 2012

How do I check, with LISP, if a System Variable is read only? In particular ANNOTATIVEDWG. This one is read/write when there are no annotative objects in a drawing, but read-only if there are.

View 7 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Change System Variable (TEXTSIZE) With Routine?

Dec 30, 2013

Is it possible to change the system variable "TEXTSIZE" with an autolisp routine? I have hundreds of drawings that have varying textsize settingings and I can't get it to let me change it, unless I go into "Style" and manually change the value to "0" before I run the routine, and there are simply too may drawings to do that everytime. So, is there a way to reset the textsize to 0 through Lisp?

View 5 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Continuous Dimension Lisp That Alternate Its Position

Jul 12, 2012

Is there a lisp that will allow me to do a continuous dimension, but will alternate the dimension position from low, high, low and high?  If there is no lisp already created, how to create one? 

See Continuous dimension attachment for example.

I work at a glass and glazing company and this is how we dimension mullion width and DLO. See typical window dimensioning attachment for window elevation with dimensions.

View 6 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Add String To Each Item In List Using Lisp

Nov 14, 2013

I have a list ("temp.dwg" "temp2.dwg") and would like to add the string "insert text here" into each item in the list resulting in ("insert text heretemp.dwg" "insert textheretemp2.dwg").  how would i go about doing that using LISP?

View 2 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Opening Drawings With Default Visual Style Set To 2D Wireframe

Oct 7, 2013

Is there a way to programatically set a visual style before a drawing actually opens?

We have some huge models and people seem to forget to change their visual styles back to 2D wireframe before saving and exiting drawings.  Some models will crash on some workstations when trying to open in a rendered mode.

I found a lisp with a function that looked to set viewport visual styles.  But it does not seem to be supported anymore. --> (vla-put-VisualStyle vport 1)

View 9 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Write A Lisp Routine That Invoke The Mleader Command

Oct 11, 2012

I'm trying to write a lisp routine that, when I invoke the mleader command, osmode is set to "nearest" & orthomode is set off. I then would like the original settings to be returned.

attached is what I have written so far:-

View 4 Replies View Related

AutoCAD Visual LISP / AutoLISP :: Visual Effect Settings?

Jun 20, 2013

Lisp that switches back on Selection Preview i.e. thickens and highlights lines when you hover over them?I don't know why, but they are always unticking the boxes.

View 4 Replies View Related

AutoCAD .NET :: Extract All System Variables

Oct 14, 2011

I was wondering if there is any way to dump out all system variables with current value in a text file. One way would be to have the variable names already preset in a list of strings then extract them. But is there any other faster way? I need to compare some drawings side by side.

View 6 Replies View Related

AutoCad :: Baseview System Variables

Jun 17, 2013

when using baseview / viewbase how can I make the resulting views linetypes, weights and colors what I want by default. Currently I change them after creating the views.

View 3 Replies View Related

AutoCad 2D :: Insert PDF - Make Sure Object Is Entered In System Registry

May 2, 2011

if i try copy/paste or paste special i get this: 'failed to create object. make sure the object is entered in the system registry.

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved