Need help creating a lisp to restore viewport layer state
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello,
I am an engineer who was assigned to do some programing by my boss. I understand basic logic, but i have no knowledge of the coding language that is used. I have multiple files that are on average 60 tabs each, and each file i need to restore a layerstate in the viewport on selected tabs. I do not mind opening each file and running it for each, to make it simpler and for the potential for easier use on future projects.
Idealy, im looking for a LISP that can:
-Ignores the Model
-Search the tabs for "B" and only apply changes to those tabs. (The tabs are labeled 1B, 1T, 1U, 1H, 2B, 2T, 2U, 2H....56B, 56T, ..... ect)
-For the viewport in the tab, change the layerstate to "LayerStateName"
-Return to Paperspace
I assume that to do this I need to make an array/list, put all the tabs that contain a "B" into the array/list, and then run a for-each statement on the array/list that will restore the layerstate in just the viewport and not paperspace. then return to paper space.
Thank you in advance for the help