Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

What is Preferred Way to Organize Macros? 2

Status
Not open for further replies.

jzecha

Aerospace
Jan 20, 2016
235
US
What is the preferred way to organize and access Catia Macros?

I have both scripts and VBA codes.

For the scripts I just placed them in a common folder on the network so everybody can navigate there to either launch each one out of the Macro menu or create icons.
Is there a way to create one icon the brings up the full list of either Products Macros, Part Macros, or Drawing Macros?
I know I would have to determine which Macros I want in each list.

For the VBA macros, I have compiled them together into two different Libraries, one for 3D Macros and the other is for Drawing Macros.
Is this a good practice or should i keep each Macro in its separate library?
I would like to create a launch menu as well for this, that way there is only one icon to access all of them.

 
Replies continue below

Recommended for you

Hi.

I believe the very best way (from a user standpoint) is to have dedicated toolbars with buttons that launch macros. This can be achieved via admin settings (you should distribute FeameGeneral.CATSettings), but this would prevent user from any UI customizations.
Other option to create toolbars is to use CAA (which I actually use), but it is expensive license-wise.

The second option is to create .catalog document and put links to macros there. This is the simplest way of organizing macros from developer standpoint as it requires very little effort. The only downsides are not so friendly UI of CATIA's catalog workbench and inability to provide context-related macro filtering (say, display drafting macros only if called from Drafting workbench or with CATDrawing document being active).

The last option is to actually do what you proposed - create and additional .catvba with UserForm providing access to all you macros in a way you want it. Downside is obvious - another piece of code to maintain.

And just another tip on distributing .catvba. If you put them in a shared location from which users run it then .catvba become locked until every CATIA process is closed. This leads to obvious update issues.
 
As for storage organization, how many macros (actual end-user commands) do you have?
 
Hi

Glad to see another power user here [bigsmile] , welcome Little Cthulhu. I have same issue with my vb.net application...so, I introduce a timer to automatically close the app and try to do update from time to time.

I'm lucky because I can develop in an environment which allow me to use vb.net, but I was also developing launcher in a hta application.

Regards
Fernando

- Romania
- EU
 
Glad to see you too, Ferdo!

You talk about "application", single. Is it some kind of launcher or your users really need just one application?
 
I believe, this forums doesn't have personal messages? If so, I have no other option than to keep posting in this thread.

Ferdo, do you have a dedicated thread for TST (as it surely deserves one), so that I could get more details aboit how it works?
 
There are several threads, I didn't check if some of them are already closed but I suppose they are since this is an old subject.

TST is a compiled exe, working with DS dll (r21), everything stored in a portable folder, including help/description files and some other utilities. Is working also with CATIA working with VPM v5, also with CATIA on a virtual desktop (and VPM v5).

Just a single instance of CATIA, no V6, error messages, warnings, working in different networks, certain users allowed to use it, time expiration (to force users to get latest updates)... frankly speaking I didn't have time to study how to do it in V6 even I would love to do it (but I done a somehow similar catvba, you can see it on my LinkedIn articles)...should modify also the code inside, I saw there are differences between v5 and v6.

Regards
Fernando

- Romania
- EU
 
I find the best way to create separate application (.exe) using vb.net in visual studio (or alternative). Easy to deploy with no user settings :) To protect the code, I just read the Windows user and give access only to desired users.
 
I have maximum 30 users and for the moment only one software developer ... me.
No issue to distribute the tool, only the issues inside the code :)
 
Because I am Japanese, it may be incorrect English.

I have created a form for macro startup. (CATVBA)
Simply fill out the tag in the header part of the module file and add it to the VBA project,
the macro start button will be added.

I upload source code here.
Link

Processing of out process macros is slow and can only be used for the first CATIA that started, so most of the macros I make are CATVBA.
 
Hello kantoku

I saw several months ago your blog and is really very interesting and full of samples, it would be great to answer here on the forum more often, Google translator is good enough for Japanese, believe me, I understood a lot from your blog.

Your catvba is somehow similar with what I've done for V6R2013x few years ago and for 3DEXPERIENCE several months ago (I saw you are interested in this subject, here are all my articles about this.

And also you can find on my YouTube channel several videos.

0_wblbhe.jpg


1_cexavk.jpg








Regards
Fernando

- Romania
- EU
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top