How to automatically create a MText spaced every 100mm ?

How to automatically create a MText spaced every 100mm ?

Anonymous
Not applicable
514 Views
2 Replies
Message 1 of 3

How to automatically create a MText spaced every 100mm ?

Anonymous
Not applicable

Is it possible for the marking the starting point and end point through PromptDistanceOptions, and then according to their distance, every 100mm create a MText? However, if the distance is less than 100mm will not be created. Your help is much appreciated.

0 Likes
515 Views
2 Replies
Replies (2)
Message 2 of 3

Anonymous
Not applicable

Any suggestions are appreciated. Thanks.

0 Likes
Message 3 of 3

5thSth
Advocate
Advocate

If I understood you correctly... I dont think it should be a problem.

 

1) prompt for first point3d(2d), prompt for 2nd point3d(2d) 

1***) you may also prompt for distance that you'd like them to be created at... so it's not always 100...

2) spwn new text while their cordinates are < than 2nd point. 

http://through-the-interface.typepad.com/through_the_interface/2010/06/creating-an-autocad-mtext-obj...

 

as for the conditioning... its basic programing concept.

 should look like this;

 

newpoint=startpoint;

while(newpoint+100<endpoint)

{

newpoint=lastpoint+100;

creteMtext(newpoint);

lastpoint=newpoint;

}

 

 P.S. an exception should be made... in case the 2st point coordinate value is "smaller" than the 1st. one... to counter it... a "distance" value should be used to spwn new text.

0 Likes