Jump to content

Recommended Posts

Posted

Hello everybody,

 

I am kind of new with tables and have some questions for those who have been there. Can somebody help me out?

 

Goal:

My goal is to make a routine that extracts block data (._dataextraction) based on a previous extraction.

This is saved in a template, somewhere on the server of our company.

 

So with "one click" (or macro / command) I need a table to "appear".

This is not the problem for it is working.

Routine so far:

(defun c:ett (/ Location ScFactor TemplatePath)
 (setq TemplatePath (strcat "C:/test.dxe")
ScFactor (getvar "dimscale")
Location (getpoint "Where? ")
)
 (vl-cmdf "-dataextraction" TemplatePath Location)
(vl-cmdf "_.scale" "L" "" Location ScFactor)
 (princ)
)
(prompt "\n\t\t>>>\t Type ett to start Extraction to Table \t<<<")
(prin1)

 

Problem:

I want this table to have an extra row below all other rows.

One of the collumns should have a formula in there: SUM the above ie. "=Sum(D3:10)".

 

And if possible I would like the text "total" in the collumn before it.

See the example.

 

How to:

Is this the way to approach it?

First define the function that creates the table, with extracted data.

Then (somehow - I do not know) add a row to last (._L) entity?

 

I do not know where to begin. Any help is much appreciated!

 

Regards,

Marco

1.jpg

Posted

Thank you Lee, I will look into that!

 

Edit: there is nothing in the Autolisp Reference and also none in the Help function in the Visual Lisp Editor...

All I can find is insertrows and insertrowsandinherit but that looks like VBA to me.

 

I tried Google and there are results so I need to look further I guess.

Posted
Edit: there is nothing in the Autolisp Reference and also none in the Help function in the Visual Lisp Editor...

All I can find is insertrows and insertrowsandinherit but that looks like VBA to me.

 

Yes, the help file is written for VBA, the arguments, their format and order are all applicable to Visual LISP, so that should be all the information that is necessary :)

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