2 Replies Latest reply on Jun 21, 2018 7:26 PM by makoto.m

    Is it impossible to change the coordinates of Point object?

    makoto.m

      Hello

       

      Using Designer Automation, I want to move components, nets and others.

      I could move components and text, but I couldn't do anything else.

      I tried to write like this:

       

      foreach(Segment seg in segments){

           seg.Location(VdWhichJoint.VDJ_HIGH).Y += 1000;

           seg.Location(VdWhichJoint.VDJ_LOW).Y += 1000;

      }

       

      foreach(Line line in lines){

           line.GetPoint(0).Y += 1000;

      }

       

      But, They didn't move at all.

      Is my way wrong?

       

      Makoto

        • 1. Re: Is it impossible to change the coordinates of Point object?
          Patrick.Cashman

          The help information for both of the functions you are using indicate that the function returns a value.  It does not explicitly say that it's read-only, but most often when you can change something, it says 'Sets or Returns'. 

           

          So from what I can tell these items are read-only.

           

          The way to accomplish what you are trying to do is to get all the data for the objects you want to move, delete the source object, modify the data, then recreate a new object using the modified data. For example store the net name of the wire in a variable called net, then store the coordinates of the wire segments in an array, then use the AddNet function to create a new wire. There may be more details involved in doing that, but that's the general idea.

           

          Take note you also want to use the Refresh method of the View after doing the changes, or sometimes they will not display on the screen even though they happened, and you might think nothing happened.

          • 2. Re: Is it impossible to change the coordinates of Point object?
            makoto.m

            Because "dxdesigner_auto.pdf" says "Returns or sets...", I thought that.

            But, I understood you saying.

            I'd like to create the objects Automation cannot move.

             

            Thank you.