VBA Forms - how do I distribute?

sam
Advocate
Advocate

VBA Forms - how do I distribute?

sam
Advocate
Advocate

Hi Everyone, 

 

With help of this wonderful community I have been able to learn a lot in last couple of months, though still a long way to go. 

I have created a VBA that creates custom parts as per given selections and inputs of button and then it assembles them in an assembly and later it creates drawing for each part. I have read various posts (& AU classes) on subject of VBA and Add-ins and I understand that distribution of VBA is not easy. My question is, whether is there any possibility to run this form through button on tool bar or may be through a Macro? 
Any reply or reference to help material will really be appreciated. 

PS. I am trying hard to get Visual Studio installed but it definitely take long to get a reply for that. 

 

Best regards, 

sam

0 Likes
Reply
Accepted solutions (3)
863 Views
12 Replies
Replies (12)

bradeneuropeArthur
Mentor
Mentor
Accepted solution

Can you store your VBA project on shared network drive?

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

sam
Advocate
Advocate

@bradeneuropeArthur Yes, I guess that could be done. How would that help?

0 Likes

bradeneuropeArthur
Mentor
Mentor

Because all users use the same project within inventor then.

If you change something, this will be available directly to all users!

 

Regards,

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

sam
Advocate
Advocate

@bradeneuropeArthur Thanks for that - that I guess will solve the problem partly. Any suggestion/help for this part in my OP.

 

whether is there any possibility to run this form through button on tool bar or may be through a Macro? 

 

Best regards, 

sam

0 Likes

bradeneuropeArthur
Mentor
Mentor

Please ask what you need and i will guide you through...

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

bradeneuropeArthur
Mentor
Mentor

You can add macro-buttons yes!

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

sam
Advocate
Advocate

@bradeneuropeArthur wrote:

Please ask what you need and i will guide you through...


Sure - Lets suppose that everyone has access to the project through shared drive as suggested by you. 

Now - whenever I need to access this form I to VBA Editor and press (F5) Run UserForm to see the form. Is there any way that a user could shoot this off from an icon on tool bar (or anything  else to avoid opening VBA editor)
best regards, 

sam

0 Likes

sam
Advocate
Advocate

 


@bradeneuropeArthur wrote:

You can add macro-buttons yes!


@bradeneuropeArthur Thanks. Please consider that I don't know really much (though I have foolishly claimed in OP that I have learned a lot).. So you mean I can call this form through macro and macro can be activated through a button on tool bar? Would you mind elaborating this in little detail (whenever possible for you). 

best regards, 

sam

0 Likes

bradeneuropeArthur
Mentor
Mentor
Accepted solution

you need to add a bitmap with the same name as the module to the folder with the vba modules.

 

keep reading for details

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

0 Likes

bradeneuropeArthur
Mentor
Mentor

like this:

 

https://forums.autodesk.com/t5/inventor-customization/no-customicon-to-vba-macro-button/td-p/9061649

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

0 Likes

bradeneuropeArthur
Mentor
Mentor
Accepted solution

use a single module to show your form, like:

Show.GIF

You can now add this module to the ribbon of inventor:

Showadd.GIF

 

Hope this explains.

Regards,

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2024 | Vault Professional 2022 | Autocad Mechanical 2022
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

sam
Advocate
Advocate

@bradeneuropeArthur Thank you so much for patiently explaining this to me. I will keep on digging more resources (and links you provided). 

 

best regards, 

sam