adding module to API stops main() from running?

So I'm working with a Solidworks macro I inherited.

If I edit the macro in SW: under Modules, I have a Main:

Public Sub main() FormBOM.show() end sub

When I play my macro it shows my form.

Now I add another Module, ECN: I then play the same macro, here's the weird part, the 2nd to last function module ECN is run... and the Main:Main() is never called.

I remove module ECN and rerun the macro, Main() appears to be called again -- my form appears

Can anyone imagine what i'm missing here? Thanks, Derek

Reply to
Derek Ciula
Loading thread data ...

"Sub Main" needs to be the last subroutine in the first module. Cut-Paste to switch orders.

Reply to
That70sTick

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.