Jump to content
Sambuddy

Batch Find & Replace - LEE MAC

Recommended Posts

Sambuddy

Does anyone know where the file is saved each time you load the "LIST" that you saved on this amazing LISP?

http://www.lee-mac.com/bfind.html

The reason I am asking is because I would like to transfer my list onto another computer but I cannot find where the file is located when you save your list to then "Load search items list"!

image.png.150f10a59d30c91513b02a7cfc599895.pngimage.png.5d73f3de88814f9cc2c4e979c3a8a5f7.png

Thanks

Share this post


Link to post
Share on other sites
rlx

Knowing master Lee he often uses roamable prefix. Looking at his code :

 


(defun _GetSavePath ( / tmp )
    (cond      
      ( (setq tmp (getvar 'ROAMABLEROOTPREFIX))
        (strcat (vl-string-right-trim "\\" (vl-string-translate "/" "\\" tmp)) "\\Support")
      )
      ( (setq tmp (findfile "ACAD.pat"))
        (vl-string-right-trim "\\" (vl-string-translate "/" "\\" (vl-filename-directory tmp)))
      )
      ( (vl-string-right-trim "\\" (vl-filename-directory (vl-filename-mktemp))) )
    )
  )


 

in this case (getvar 'ROAMABLEROOTPREFIX) gives a folder and added is a subfolder \Support

so it could be something like :

 

folder :

c:\Users\rlx\AppData\Roaming\Autodesk\AutoCAD 2017\R21.0\enu\Support\

 

files :

LMAC_BFind_V2-0.cfg

LMAC_BFind_SavedSearches_V2-0.txt

 

🍷 🛌😴💤

 

 

 

  • Thanks 1

Share this post


Link to post
Share on other sites
Lee Mac

Save some find/replace pairs, then type the following at the AutoCAD command-line:

(findfile "LMAC_BFind_SavedSearches_V2-0.txt")

 

Share this post


Link to post
Share on other sites
Sambuddy
14 hours ago, rlx said:

Knowing master Lee he often uses roamable prefix. Looking at his code :

 

 


(defun _GetSavePath ( / tmp )
    (cond      
      ( (setq tmp (getvar 'ROAMABLEROOTPREFIX))
        (strcat (vl-string-right-trim "\\" (vl-string-translate "/" "\\" tmp)) "\\Support")
      )
      ( (setq tmp (findfile "ACAD.pat"))
        (vl-string-right-trim "\\" (vl-string-translate "/" "\\" (vl-filename-directory tmp)))
      )
      ( (vl-string-right-trim "\\" (vl-filename-directory (vl-filename-mktemp))) )
    )
  )


 

 

in this case (getvar 'ROAMABLEROOTPREFIX) gives a folder and added is a subfolder \Support

so it could be something like :

 

folder :

c:\Users\rlx\AppData\Roaming\Autodesk\AutoCAD 2017\R21.0\enu\Support\

 

files :

LMAC_BFind_V2-0.cfg

LMAC_BFind_SavedSearches_V2-0.txt

 

🍷 🛌😴💤

 

 

 

 

Thank you rlx - I always appreciate your help

  • Like 1

Share this post


Link to post
Share on other sites
Sambuddy
13 hours ago, Lee Mac said:

Save some find/replace pairs, then type the following at the AutoCAD command-line:


(findfile "LMAC_BFind_SavedSearches_V2-0.txt")

 

Thank you Lee Mac - now I can load my list and easily transfer it to other PCs.

Great LISP - you have no idea how helpful it is for my daily work!

Share this post


Link to post
Share on other sites
Lee Mac
30 minutes ago, Sambuddy said:

Great LISP - you have no idea how helpful it is for my daily work!

 

Glad to hear it! 🙂

  • Thanks 1

Share this post


Link to post
Share on other sites
Sambuddy
11 minutes ago, Lee Mac said:

 

Glad to hear it! 🙂

Hey Lee Mac,

I have trying to write a lisp to make the process of importing the workspace and profile easier to other PCs. Could you please also help me on that. So far with the help of BIGAL I discovered there is a profile that can be transferred to other PCs, but it does not carry all the changes on the saved workspace - Could you help me find out how it is that I can import all my settings both of physical look of a saved workspace/ saved support paths and profile seamlessly.

 

As far as I got it it seems to do a random job where some parts are missing on one PC and good enough on others but never consistant. Example: I set/ dock my properties pallet on the left and External references on the right when I save my workspace - but on a new PC, I do not have them at all or when I check or uncheck certain options it does a random job of checking sometimes.

 

Could you please help?

Thanks,

Sam 

Share this post


Link to post
Share on other sites
BIGAL

I had scripts for each user that loaded their toolbars to their preferences, not every one wants it on left. Yes you had to save workspace again it was to their name not a company name. So you could go on someone elses pc and load workspace Sambuddy.

 

Whilst on this topic I have custom menu's using CIV3d I do not change workspaces as I have CIV3D options in my custom menu's saves a lot of swapping. So you can have a workspace with bits and pieces of other workspace commands. Just need to copy out of menu's using CUI.

  • Thanks 1

Share this post


Link to post
Share on other sites
Sambuddy
12 hours ago, BIGAL said:

I had scripts for each user that loaded their toolbars to their preferences, not every one wants it on left. Yes you had to save workspace again it was to their name not a company name. So you could go on someone elses pc and load workspace Sambuddy.

 

Whilst on this topic I have custom menu's using CIV3d I do not change workspaces as I have CIV3D options in my custom menu's saves a lot of swapping. So you can have a workspace with bits and pieces of other workspace commands. Just need to copy out of menu's using CUI.

Thanks again BIGAL,

 

Your nickname definitely suites your presence here on this forum. I always learnt from you and you comments since I have been posting at CADTUTOR. My greatest of appreciations!

I do realize CUI must be transferred for a complete preference I am trying to establish on each PC, but my question was so much about the unifying method to accomplish the task without having to go in it again and complete the missing parts - imagine this: a standard that you feel is best to set the PCs, then of course everyone could move along with their changes and preferences once they take ownership of that PC. I myself as using SolidWorks and not much of a need for AutoCAD these days but there was a way that all my setting profiles and CUI could be set!

You suggestions in the past had guided me A LOT and I hope to receive some more, even though radical or untested, could help me accomplish this task.

 

Thanks again

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...