Hot News:

Mit Unterstützung durch:

  Foren auf CAD.de (alle Foren)
  PTC Creo Elements/Direct Modeling
  Name compatibility problem when saving with sd*

Antwort erstellen  Neues Thema erstellen
CAD.de Login | Logout | Profil | Profil bearbeiten | Registrieren | Voreinstellungen | Hilfe | Suchen

Anzeige:

Darstellung des Themas zum Ausdrucken. Bitte dann die Druckfunktion des Browsers verwenden. | Suche nach Beiträgen nächster neuer Beitrag | nächster älterer Beitrag
  
Gut zu wissen: Hilfreiche Tipps und Tricks aus der Praxis prägnant, und auf den Punkt gebracht für PTC CREO
Autor Thema:  Name compatibility problem when saving with sd* (292 / mal gelesen)
renchaoroy
Mitglied
Engineer


Sehen Sie sich das Profil von renchaoroy an!   Senden Sie eine Private Message an renchaoroy  Schreiben Sie einen Gästebucheintrag für renchaoroy

Beiträge: 13
Registriert: 05.06.2021

DELL-Precision 3530/Intel(R) Core(TM) i7-8850H CPU @ 2.60GHz 2.59
GHZ/16.0 GB/Windows 10 Home/20H2/OS revision19042.985/DirectModeling (x64edition)/Revision: 19.0/Datecode: F000(19.0.0.790,09-May-2014)

erstellt am: 17. Dez. 2023 14:46    Editieren oder löschen Sie diesen Beitrag!  <-- editieren / zitieren -->   Antwort mit Zitat in Fett Antwort mit kursivem Zitat    Unities abgeben: 1 Unity (wenig hilfreich, aber dennoch)2 Unities3 Unities4 Unities5 Unities6 Unities7 Unities8 Unities9 Unities10 Unities


Jpg01.jpg


Jpg02.jpg


Jpg03.jpg

 
Dear friends, winter is coming, may everyone's life be full of warmth. 

I have a Question:
When using sd* to save files, today (20231217) I saved "Part 1" to the disk and generated "Part 1.SDPC", tomorrow (20231218) I modified the geometry of "Part 1", when saving again, the new data will overwrite the original "part 1.SDPC".

Question:
1. Later (for example, 20231224), I cannot restore "Part 1" to the state of 20231217.
2. If I tomorrow (20231218) within the CreoElementsDirectModeling  "part 1" of the name change to "bracket", but when saved to disk, the file name is still "part 1.SDPC". If I want to modify the "bracket" part separately, I can not find the corresponding file on the disk.

Excuse me:
what method can accurately know CreoElementsDirectModeling within a certain part(object) corresponding file name on the disk?


------------------
A mechanical engineer who loves to program  

[Diese Nachricht wurde von renchaoroy am 17. Dez. 2023 editiert.]

Eine Antwort auf diesen Beitrag verfassen (mit Zitat/Zitat des Beitrags) IP

highway45
Moderator
Bastler mit Diplom




Sehen Sie sich das Profil von highway45 an!   Senden Sie eine Private Message an highway45  Schreiben Sie einen Gästebucheintrag für highway45

Beiträge: 6361
Registriert: 14.12.2004

SolidDesigner-20.5.0 + PhoenixPDM-11 + Solidworks-2023 + PE8 + Blender

erstellt am: 17. Dez. 2023 15:01    Editieren oder löschen Sie diesen Beitrag!  <-- editieren / zitieren -->   Antwort mit Zitat in Fett Antwort mit kursivem Zitat    Unities abgeben: 1 Unity (wenig hilfreich, aber dennoch)2 Unities3 Unities4 Unities5 Unities6 Unities7 Unities8 Unities9 Unities10 Unities Nur für renchaoroy 10 Unities + Antwort hilfreich

Rename it on the disk too.

Part1.sdpc has internal stored which name is shown in CAD, for example "part1" or "bracket" or "John-Boy".

If Part1.sdpc is in an assembly group like yours "exmples", then its name "bracket" is only stored there.
Try to load Part1.sdpc alone, then you see the former name "part1" again.

------------------

Eine Antwort auf diesen Beitrag verfassen (mit Zitat/Zitat des Beitrags) IP

der_Wolfgang
Ehrenmitglied V.I.P. h.c.
Tastenhauer


Sehen Sie sich das Profil von der_Wolfgang an!   Senden Sie eine Private Message an der_Wolfgang  Schreiben Sie einen Gästebucheintrag für der_Wolfgang

Beiträge: 2141
Registriert: 3.20.

● PE6+8@home
● W10 Pro Build19045.3803
● Drafting V20.1-6
● Modeling V20.1-6

erstellt am: 17. Dez. 2023 20:22    Editieren oder löschen Sie diesen Beitrag!  <-- editieren / zitieren -->   Antwort mit Zitat in Fett Antwort mit kursivem Zitat    Unities abgeben: 1 Unity (wenig hilfreich, aber dennoch)2 Unities3 Unities4 Unities5 Unities6 Unities7 Unities8 Unities9 Unities10 Unities Nur für renchaoroy 10 Unities + Antwort hilfreich

Zitat:
Original erstellt von renchaoroy:
sd*files.... corresponding file name on the disk?

In general I would recommend NOT to fiddle manually with those filenames. Using the SD-files on disk (and not using ModelManager or similar tools) you will soon have 142++ Assemblies and 474++ parts and instances and other files on disk. Renaming files might work for simple things. But you might end up in a 'file not found' issue when loading an assembly later on

And with 'later on' I mean: loading an assembly in Nov 2024, but you renamed the missing file in dec 2023! How good you do remember? 😉

If using the SD-files-on-disk approach: handle that directory as a closed black box and just TRUST Modeling. Rename objects WITHIN Modeling.

------------------
Firefox ESRJava Forum Stuttgart JUGS ● OSD Hilfeseite (de) / help page (en)NotePad++BuFDi

Eine Antwort auf diesen Beitrag verfassen (mit Zitat/Zitat des Beitrags) IP

renchaoroy
Mitglied
Engineer


Sehen Sie sich das Profil von renchaoroy an!   Senden Sie eine Private Message an renchaoroy  Schreiben Sie einen Gästebucheintrag für renchaoroy

Beiträge: 13
Registriert: 05.06.2021

DELL-Precision 3530/Intel(R) Core(TM) i7-8850H CPU @ 2.60GHz 2.59
GHZ/16.0 GB/Windows 10 Home/20H2/OS revision19042.985/DirectModeling (x64edition)/Revision: 19.0/Datecode: F000(19.0.0.790,09-May-2014)

erstellt am: 16. Jan. 2024 05:12    Editieren oder löschen Sie diesen Beitrag!  <-- editieren / zitieren -->   Antwort mit Zitat in Fett Antwort mit kursivem Zitat    Unities abgeben: 1 Unity (wenig hilfreich, aber dennoch)2 Unities3 Unities4 Unities5 Unities6 Unities7 Unities8 Unities9 Unities10 Unities

Thank you to my friends Matthias and Wolfgang,
According to offer you the information, I found in the preservation, if the model objects have contents name, CreoElementsDirectModeling contents is used the name as a disk file name to save. If not, the file is saved on disk using the same string as the base name.
And save, only changed the contents name save again, CreoElementsDirectModeling will use the new contens name save a new file on disk. Otherwise, the file name on disk will always be the string from the first save.

I've now solved the problem with version names when saving files using the following method
1. The name of the file object to iterate over the save path (eFileName)
2. Lookup the name of the modified model object (mObjName)
3. Check if mObjName exists a file with the same name in the disk path
3.1. Rename the disk file name (incrementing the version number) if a disk file with the same name exists
3.2. If no disk file with the same name exists, no action is taken.
4. Save the modified model object (use mObjName).

There are still two problems with this,
An error if a model object with the same name exists in the drawing environment,
b. If you change the contents name and save it again, you cannot trace the historical version by the file name.

I will continue to work on how to solve this problem. If you have a way to trace back to a historical version without a common file name, please let me know. Thank you again.
 

------------------
A mechanical engineer who loves to program 

Eine Antwort auf diesen Beitrag verfassen (mit Zitat/Zitat des Beitrags) IP

Anzeige.:

Anzeige: (Infos zum Werbeplatz >>)

Darstellung des Themas zum Ausdrucken. Bitte dann die Druckfunktion des Browsers verwenden. | Suche nach Beiträgen

nächster neuerer Beitrag | nächster älterer Beitrag
Antwort erstellen


Diesen Beitrag mit Lesezeichen versehen ... | Nach anderen Beiträgen suchen | CAD.de-Newsletter

Administrative Optionen: Beitrag schliessen | Archivieren/Bewegen | Beitrag melden!

Fragen und Anregungen: Kritik-Forum | Neues aus der Community: Community-Forum

(c)2024 CAD.de | Impressum | Datenschutz