From the course: Learning AutoLISP & Visual LISP
Unlock the full course today
Join today to access over 22,500 courses taught by industry experts or purchase this course individually.
Function: vla-get-preferences - AutoCAD Tutorial
From the course: Learning AutoLISP & Visual LISP
Function: vla-get-preferences
- [Instructor] In our last chapter, we looked at the VLAX-GET-ACAD-OBJECT visualLISP function, and we saw that we can store that in just a standard variable that we've learned about already, and notice that one of the properties inside, that's available, of the AutoCAD application are the preferences, and so if we double click on here, we have a list of the preferences objects. And notice they match very closely to our standard options dialog box. So we can make changes to pretty much any property within the AutoCAD options dialog box right from in our visualLISP. So let's go ahead and create another variable, and we'll call this ACADPREFS, and we get ACADPREFS from the AutoCAD object. So notice there is a similar naming convention. When we want to get an object, VLA-GET, and then the name of the property. So in this case, preferences. And then we provide it the object that has that property. We're going to store that in the variable here, ACADPREFS, We close this down, and we'll…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.