Jump to content

Recommended Posts

Posted

I'm about to receive a bunch of borehole data for a bigger project with x,y coordinates in state plane for each hole and I believe it will be sent as an Excel file. I'd like to add a center-justified text consisting of the borehole name at the x,y coordinate where it should go so I can quickly check out the location of a hole and then look up its other properties by name in the Excel sheet. So far, I'm thinking about concatenating the cells and adding spaces in a separate column in excel so that for each hole I have something like:

 

text j mc 0 x-coordinate,y-coordinate BH120

 

in a single cell. That way I can copy and paste that line at the CAD command prompt and skip a ton of key strokes going through the text options.

 

I've done a similar workaround, inspired by someone here on the forums, when working with line segments where clients have sent me endpoints in Excel format. It's been great because it's transparent enough that I can forward my spreadsheet on to any one of my coworkers and have them duplicate the process without having to worry about a couple of people in my work group who only have LT and can't use LISPs (I think?). The difference is that while you can exit a line command by putting a space after that entry above, I think the only way to end the text command might be by pressing enter twice and I don't know if there's a way to just concatenate a couple of enters at the end of a line like I can a couple of spaces.

 

The question is, is there a quick cheat that would let me do everything by copying and pasting multiple lines formatted as above all at once from excel without having to press enter after each hole? Is there an arraypath type command that's more well-suited to this instead, since I do have x,y coordinates?

Posted
text j mc 0 x-coordinate,y-coordinate BH120
We have a winner

 

The extra press enters may be spaces on the end of the line, you need to be careful of that, or try -text. As text now expects a new line like mtext.

To end, a blank line should work as Enter. Carefully check the lines copy and paste to notepad as a check.

Posted

I do not know why I never considered adding a blank line...doing both that and -text instead of text is going to work perfectly. Thank you for saving me many hours of frustration!

Posted

Mistakes were made. The original post above should have:

 

text j mc x-coordinate,y-coordinate 0 BH120

Posted

Just watch out for the two ways to do text compare text style with height = 0 to height is a value, the 2nd it will not prompt for height so script stuffs up.

 

text j mc x-coordinate,y-coordinate 2.5 0 BH120

text j mc x-coordinate,y-coordinate 0 BH120

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...