Message 1 of 10
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
How do I change the default C:\User....... folder to a different location?
Solved! Go to Solution.
How do I change the default C:\User....... folder to a different location?
Solved! Go to Solution.
It's a registry thing.
If your goal is to standardize this location for all users, you can either:
Thanks for confirming that, I was thinking it was a registry key.
So, to deploy the key you would need to do this for each version of C3D on a system?
How would you do this in acad.lsp (what would the syntax be) as that would be easier and have less involvement with IT.
It might look something like this in your acad.lsp file. I am using this to set the tool palette paths (which are within the profile) so I changed the values below to what you probably need. I am using c3d 2024 as well. You might have to change the version accordingly:
(Setq RegKey "HKEY_LOCAL_MACHINE\\SOFTWARE\\Autodesk\\AutoCAD\\R24.3\\ACAD-7100:409\\AEC\\Directories")
(setq ValName "ProjTemplateDir")
(setq ValData "C:\\C3D_DS-Templates")
(if
(/= (vl-registry-read RegKey ValName) ValData)
(vl-registry-write RegKey ValName ValData)
)
(setq str2 "Project Template Path Set...")
(print str2)
I'll have to explore this method. Currently our IT department locks down the registry and there's no way for users to make the edits that would be involved in making this happen. But modifying the ACAD.lsp file to make the change would be a far easier pathway forward.
If I cannot edit the registry key using REGEDIT does this mean that I won't be able to edit it with LSP as well. I just created a acad.lsp to run testing on my local machine and it doesn't change the value to the location I've provided.
The reason I ask is I changed the syntax to match my location and it's not changing to the directory I requested.
Hey. It probably will only work if you have local admin rights as CAD users. Otherwise, it would have to be done manually (yuck) or through a group policy from IT (little more yucky) or built into the deployment (little less yucky). Sorry if this is your situation. Not much you can do when the local machine is locked down.
So, I did a little more testing, this time on my personal pc where I have full admin rights to the registry and I still could not get the folder to switch, even though it would state that the acad.lsp file loaded successfully. Could there be something missing in the syntax that would report this success yet not be successful 😞
It did work going through there regedit method, I just hate getting IT involved in this sort of thing, it's like pulling teeth.
The only thing I can think of is the conditional IF portion of the code. The idea is IF the path is already correct, no need to write it again causing multiple entries. However, I think in this case you can probably remove the IF statement. So it might look like this:
(if
(/= (vl-registry-read RegKey ValName) ValData)
(vl-registry-write RegKey ValName ValData)
)
BECOMES
(vl-registry-write RegKey ValName ValData)
Thanks, I'll give that a try.
Still no go, I'm going, but it reports sucessful. I'm going to go the IT route, as this is only for one office at the moment. Which would be only 4 users. This could grow at a later date.