Jump to content

Insert shapes at given coordinates, and data extraction


cat3appr

Recommended Posts

hi all,

 

I wanted to add this to the paid service forum but I couldn't find it, I'm describing it here:

 

I need to add dwg shapes on a pipeline drawing. For each shape I have the forward and after center point:

 

image.png.40a0cbf1882a3ba084ab0019a9e54417.png

 

 

 

The forward direction is based on the direction of a pipeline, as here below,  AFT position in the East, and Forward to the West:

 

image.thumb.png.971c1e57bd525262968b2cf04dacacc9.png

 

 

 

The block will be inserted based on the AFT and FWD position, which will also define the orientation.

The AFT and FWD points are stored in these folders and the data needs to be scraped somehow:

image.png.6f0e881a6873ec7ec94bd8507d6408da.png

 

We open a folder and we find  AFT and FWD , on those .npc files,  we open them and:

image.png.dfebde3e3b1b3eea13a4a3233a9e6c88.png

 

We get the actual coordinates of the UM07 FWD :   E281883.27;  N 1779868.86

 

image.thumb.png.8122a2a17587ba9551497c160649bf18.png

 

 

 

And UTM07 AFT:  E 281888.13: N 1779872.14

 

Those 2 couples of coordinates will be used to insert the shape in the DWG  drawing:

 

image.thumb.png.56a9ade4569c10b89aeeadf77957651c.png

 

 

 

 

In some folders the  FWD and AFT positions are not calculated:

 

For example UM21 folder has those 2 files, which are different from the ones above, they don’t have an average calculated,

image.png.7c8ce1641a84887f32d6ab1e5bf25bae.png

 

 

in these cases, the first set of coordinates can be used:  as you can see the AFT coordinate is a list,  in this case, the first one can be taken for the insertion

image.thumb.png.0932e7696b5e1f3457d1480475c6896d.png

 

 

I guess the data extraction from the folders is too complex, so eventually  I could list them manually, 

as a series of Easting, Northing 

 

FW

281888.11,1779879.45

281882.12,1779877.76

AFT

281883.16,1779875.15

281886.17,1779874.12

 

and then use a Lisp to  create and place the blocks in the right coordinates , is this possible?

 

thank you

Alex

Link to comment
Share on other sites

Need a dwg and a matching file. 

 

Provided the 2 co-ords can be read from a file it should be easy. Even if the points start well down in the file. 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...