subroutines

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • subroutines

    What we would like to do if possible is to call features from one sub to another can you even do this.
    sigpic
    if you had soap on a rope it would be tied to yer ankle

  • #2
    Ya you can do this.
    Mr. Comment
    SCIROCCO-NT 13-20-10
    B3C-LC Controller (Leitz Protocol), SP600M, TP200
    PCDMIS CAD++ v4.3 MR1(Build: 12/11/08)
    sigpic

    Comment


    • #3
      Originally posted by T Miller View Post
      What we would like to do if possible is to call features from one sub to another can you even do this.
      Does this go back to similar parts like you mentioned earlier? Have you ever written something parametric? You might want to try writting a variable program. Mr Comment is probably the right guy for subs as he has posted some of his struggles with them but what are you up to exactly, or would you have to kill me if you told?
      <internet bumper sticker goes here>

      Comment


      • #4
        Tom,

        You need to create a print command in the subroutine prog or create the dimensions in the main prog.

        To do this, you need to create a dimension in the current program. Copy and paste it and change feature name to subroutine label followed by a colon and the feature name in that subroutine. Need to run the subroutine first before it will allow you to type the name.

        When it prints out, it will show the dimensions for the subs that don't run as NOT_USED. The one it does run will show up as CS1:CIR1 in command mode (sub label:feature name) but in report mode it will show only as the feature name.

        Watch for duplicate IDs in the dims.

        HTH
        PC-DMIS CAD++ 3.7 from 4.2 MR1

        Comment


        • #5
          We have a group of parts .
          It is a lot of different parts in the group but have a lot of the same features.

          The starting location will be the same on them all. What they have so far is a program to set the start location and want to call a sub to check a few diamters on one end of the part. They did another alignment to off set start point in the -y direction and call another sub to check the other end that even goes well. But what they need is a few distance call from features in the other sub.. is that clear?
          sigpic
          if you had soap on a rope it would be tied to yer ankle

          Comment


          • #6
            Originally posted by JoeRZ View Post
            Tom,

            You need to create a print command in the subroutine prog or create the dimensions in the main prog.

            To do this, you need to create a dimension in the current program. Copy and paste it and change feature name to subroutine label followed by a colon and the feature name in that subroutine. Need to run the subroutine first before it will allow you to type the name.

            When it prints out, it will show the dimensions for the subs that don't run as NOT_USED. The one it does run will show up as CS1:CIR1 in command mode (sub label:feature name) but in report mode it will show only as the feature name.

            Watch for duplicate IDs in the dims.

            HTH
            Did a small simple test of this and seems to be something I can use.. Thanks
            Tom
            sigpic
            if you had soap on a rope it would be tied to yer ankle

            Comment


            • #7
              No Prob T,

              I was trying to upload the files (examples) but having problem...telling me it's invalid. I could not post the code because PC-DMIS not on Internet - I was trying to do attachments and just won't allow the .prg files.

              Joe
              PC-DMIS CAD++ 3.7 from 4.2 MR1

              Comment


              • #8
                Originally posted by JoeRZ View Post
                No Prob T,

                I was trying to upload the files (examples) but having problem...telling me it's invalid. I could not post the code because PC-DMIS not on Internet - I was trying to do attachments and just won't allow the .prg files.

                Joe
                You could send them to my email addy
                sigpic
                if you had soap on a rope it would be tied to yer ankle

                Comment


                • #9
                  Fo Sho...
                  PC-DMIS CAD++ 3.7 from 4.2 MR1

                  Comment


                  • #10
                    I forgot - what's your e-mail?
                    PC-DMIS CAD++ 3.7 from 4.2 MR1

                    Comment


                    • #11
                      email

                      Originally posted by JoeRZ View Post
                      I forgot - what's your e-mail?
                      [email protected]
                      sigpic
                      if you had soap on a rope it would be tied to yer ankle

                      Comment

                      Related Topics

                      Collapse

                      Working...
                      X