Edit properties from Excel for Solidworks with the Document manager API

In order;

Coool!
I have not applied for our 2022 versions.
I should be able to do so as soon as I receive a valid key.
That's too bad.

Thank you @remrem

Kind regards.

Hi Maclane,
I'll see to make you a lighter version of my Excel supplement so that you can test.
I'll keep you informed.
Have a nice day.

Hi @remrem ;

I just made a new key request to Solidworks. Wait & see...

Thank you for the proposal (what language did you use for your complement?).

As I'm taking my first steps with Document Manager, I'll start with CodeStack's VBA macro below:
CodeStack-Document Manager

But I'm open to all solutions: :grin: (As long as I understand the code.)

It's funny all the same, it's @JnO who was asking for it at the beginning and I'm the one who benefits the most... :stuck_out_tongue_winking_eye:, but I think he'll also find something to his liking.

Kind regards.

Lynkoa is a place of sharing. :wink:

I coded it in net VB.

Hello

Small question that will help everyone, you need a 64-bit Excel right? In 32 I have errors while under SW it passes without problem.

What mistakes?

Active error x of memory, not retested since.
Under SW it works as it should, the only difference is the 64 bits. I have other macros in Excel that work very well with SW or PDM but Document Manager is buggy

I don't think it comes from that. I'm in 32.

Class not registered from the beginning of the macro (the active problem x was something else, I just remembered).

Dim swClassFact As SwDocumentMgr.SwDMClassFactory
Set SwClassFact = New SwDocumentMgr.SwDMClassFactory

I have the references enabled, works well under SW directly. So either I have a problem with the automatic installation (it's possible with 365 and its regular updates) or I dry up.

Active X is good (it was my key that was not complete, see message of January 25th), now it's the message class not registered.
I have this message only on Execl with the same type of code on SW no problem

Thanks guys, this will surely help me in tur-fu :kissing_heart:. In the meantime I'm overwhelmed with work, I didn't have time to test...
I'll continue to take a look at the forum from time to time, in any case I'm keeping this very interesting post under my belt. I'll keep you updated when I've started, I'll probably have a lot of problems :exploding_head: !

Macrotement

JnO

@Cyril.f

It seems that you are using the Excel macro of CodeStack... In this case, I confirm that it ONLY works under Office 64b.

  • I did the test with a PC in Office 32 (+Solidworks 2022 64b): The Classes are not loaded.

  • the same test between a PC in Office 64 (+Solidworks 2022 64b): no error messages, everything works the first time.

  • the same test between a PC in Office 64 (Without Solidworks): Error, not identified for the moment. (You probably need to load the Document Manager SDK).

Kind regards.

I have Office 32 and SW 2022 64b, no problem with the same code on SW on the other hand on Office it sucks.

Hello;
I revive the subject with a " Document Manager " application found on the site:
3dexprerience (Logs required) or here: forum.solidworks which seems promising...

Author: Fifi Riri

Description:
Functions:

- change a custom property value in a file by editing its cell
- change a custom property value in all the files by defining the column's rule, then apply it by right-clicking the column header
- add or remove a custom property by right-clicking the column header
- save the columns' name and rules for next use

Written in C# (Visual_Studio)
The code is relatively well commented.
… Configuration management is " curious " but the bulk of the work is there.

Kind regards.

2 Likes

The Fifi Riri from the 3Dexperience site is also @JeromeP on our forum for information, even if not present for a while.

1 Like

So a big thank you to @JeromeP . :grinning: (thanks @sbadenis for the info)

Can I mess around in your program? Be careful, I'm a beginner in c# so it's possible that I'll do some stupid things...
Do you have a newer version to share?

Kind regards.

Of course @Maclane. I've included the sources for that.
There would certainly be improvements to be made...

I made this version some time ago (to save the columns in a txt file) but not published:
BatchCustomProp034.zip (312.2 KB)

2 Likes