A change in file location; how to handle this?

Discussion about the development of the Assembly workbench.
kbwbe
Veteran
Posts: 1049
Joined: Tue Apr 10, 2018 3:12 pm
Location: Germany, near Köln (Cologne)

Re: A change in file location; how to handle this?

Post by kbwbe »

Koemi wrote: Fri Dec 21, 2018 12:29 pm
i feared that (library folders). I work similar too.
Regarding script problems: It does not recognize the stringvalue in OLD_CAD_FOLDER. Therefore it replaces nothing. Please check that the entered string is really correct.
If it is, we have perhaps a unicode/encoding problem, so that strings are not compared correctly.
KBWBE

https://github.com/kbwbe/A2plus
latest release: v0.4.56, installable via FreeCAD's addon manager
Tutorial: gripper assembly https://www.youtube.com/watch?v=QMxcQ5tssWk
Documentation: https://www.freecadweb.org/wiki/A2plus_Workbench
Koemi
Posts: 142
Joined: Thu Dec 28, 2017 11:13 am
Location: The Netherlands

Re: A change in file location; how to handle this?

Post by Koemi »

I will look at it in 2019. Take care guys.

Thanks for now for your help.

The best wishes for 2019 in advance, have a good one :D
triplus
Veteran
Posts: 9475
Joined: Mon Dec 12, 2011 4:45 pm

Re: A change in file location; how to handle this?

Post by triplus »

Koemi wrote: Fri Dec 21, 2018 12:29 pm If I understand triplus correctly: no. It would be quite a hassle...

Because my assemblies can contain parts from several other folders, like: tools, hinges, profiles, electronics, logistics, etc. These folders are in fact libraries of parts. I am quite sure I am not the only one who works like this.

To create what triplus says, I have to put all parts in the same folder as the main assembly (that would be quite a job). The 'Pack & Go' function of SolidWorks does exactly the same in a single click. It 'grabs' everything necessary to build the assembly and makes a package of it. But connections of the library-folders are gone. So it is a fast but not perfect solution.
But this is a common sense problem in the end isn't it? If you want the assembly file to be portable, you can't rely on absolute paths for part files. Assembly 2 therefore supports relative paths in addition to absolute paths. A2plus offers "project folder" and in Assembly 3 end user can create a Link feature. Such feature can at any time be imported into the assembly document, if needed. Hence i guess making the assembly document fully portable.

In the future there might be some additional solutions. Like FreeCAD assembly to be aware of some catalog of parts on remote server or inside some folder structure. And therefore assembly file itself to be small, but the catalog and the path to it needs to be provided. To access and use parts from it. Again, to make such assembly file portable, when access to parts catalog can't be provided. Or when the catalog of parts is just too big, to be distributed together with the assembly file, we are back to (similar) solutions Assembly 2 (and others) already provide. ;)
Koemi
Posts: 142
Joined: Thu Dec 28, 2017 11:13 am
Location: The Netherlands

Re: A change in file location; how to handle this?

Post by Koemi »

Koemi wrote: Wed Dec 19, 2018 8:59 am For instance (from Z:\blabla\FreeCAD_files\ to another like for instance D:\raldiedal\etc\FreeCAD_files\).

So I am expecting that parts cannot be found, drawings unreachable etc.

How to handle this?

Any workbench available, or will this be a week of hell to recreate new assemblies / changing locations of every part.... :shock:
*bump*

Well folks, it is going to happen. Complete server change at the office with this change in file location. So... I've got a problem. I think. Or not?

I am expecting problems with assembly files searching for files in a path which has been changed.

Is there some solution?


OS: Windows 10 Version 2009
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24267 +99 (Git)
Build type: Release
Branch: Branch_0.19.3
Hash: 6530e364184ce05ccff39501e175cf2237e6ee4b
Python version: 3.8.6+
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.3
Locale: Dutch/Belgium (nl_BE)
Koemi
Posts: 142
Joined: Thu Dec 28, 2017 11:13 am
Location: The Netherlands

Re: A change in file location; how to handle this?

Post by Koemi »

Hi Koemi !
Which Assembly Module ? A2/A2p ?
With A2p you can you can use the option "use project folder" in preferences. Everything (assemblies, sourcefiles) have to below this, regardless where.
Or is this my lifesaver? Apart from the early files created in A2... What to do with these?
Image 7.png
Image 7.png (6.2 KiB) Viewed 129 times
adrianinsaval
Veteran
Posts: 3194
Joined: Thu Apr 05, 2018 5:15 pm

Re: A change in file location; how to handle this?

Post by adrianinsaval »

if that doesn't work you can probably make a macro to replace the old path to the new path in your files, or alternatively you could create a symlink in the old location to the new location.
Post Reply