18 Replies Latest reply on Jul 13, 2018 3:52 PM by Said Kacioui

    MACRO NOT RESPONDING

    Said Kacioui

      Hi everyone

       

      i have a macro to consolidate my parts in SQL Database , when i restart my computer the macro works (After some times ) but if i did not restart my PC,  the macro and SW stay without response for a long time , until i decide to force SW closing

       

      Someone can help if he face such a situation before ?

       

      Best regards

        • Re: MACRO NOT REPONDING
          Josh Brady

          You have a bug in your code somewhere.  I have faced bugs in my code many times in the past.  There are several different types of bugs.

           

          WTF else are we supposed to say? The quantity of information you have provided is indistinguishable from zero.

          • Re: MACRO NOT RESPONDING
            Alex Lachance

            I use a 3rd party program that is SQL based to sort my projects out and also take care of part numbering, descriptions and a lot more.


            I also use a macro to send information to my E.R.P. The macro send info to the SQL database of the E.R.P.


            When I run the macro to send the information to the database, it blocks out the SQL database search until I either restart the add-on or SolidWorks. Maybe that's what is happening here for you?

             

            I've had both the E.R.P. programmers and the Add-on programers talk to each other and they just can't seem to agree on what is the root cause. It looks like a bunch of kids who got caught doing something they weren't allowed and don't want to admit it.

             

            Add-on Programmer: ''The error comes from the E.R.P., not the Add-on''

            E.R.P. Programmer : ''That can't be, we can run the macro fine without your add-on and no problems''

            ''Add-on Programmer : ''Well we can run our Add-on and the program without problem too''

            E.R.P. Programmer :''...Well it's still your fault, everything is good on our side''

            Add-on Programmer : ''No it's your fault!''

             

            And so the conversation continues...

            • Re: MACRO NOT RESPONDING
              Said Kacioui

              This is where the problem occure

               

              swParentComp.Select (False)

               

              when I suppress this line Locking works even if the progress bar do not reach 100%

               

              someone can tell me if the code for parrent component is usefull for SW 2018 ?

              thanks