Author Topic: MAPTRIM via lisp?  (Read 4357 times)

0 Members and 1 Guest are viewing this topic.

CHulse

  • Swamp Rat
  • Posts: 504
MAPTRIM via lisp?
« on: October 30, 2015, 02:43:08 PM »
Does anyone know if it's possible to access the MAPTRIM command (in MAP or C3D) via lisp?
As far as I know, you can't run it via command line...

Thanks
Cary Hulse
Urban Forestry Manager
Wetland Studies and Solutions

Civil 3D 2020 & 2023

squirreldip

  • Newt
  • Posts: 114
Re: MAPTRIM via lisp?
« Reply #1 on: October 30, 2015, 04:54:15 PM »
Will C:EXTRIM work for you (from Express Tools)?

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: MAPTRIM via lisp?
« Reply #2 on: October 30, 2015, 04:56:53 PM »
due to the dialog interface, probably not
Be your Best


Michael Farrell
http://primeservicesglobal.com/

topograph

  • Mosquito
  • Posts: 4
Re: MAPTRIM via lisp?
« Reply #3 on: October 31, 2015, 05:38:35 AM »
Does anyone know if it's possible to access the MAPTRIM command (in MAP or C3D) via lisp?
As far as I know, you can't run it via command line...

Thanks

(command "maptrim" "d" point1 point2 point3 point4 "" "n" "n" "o" "y" "y" "i" "y")


where
  "d" -> Enter trim boundary method (Query/Select/Define):d
    point1 point2 point3 point4  ->coordinates of polygon you want cutting
  "" -> no more points
  "n" ->Filter objects to trim by layer? (Yes/No) <N>: n
  "n" ->Select objects to trim manually? (Yes/No) <Y>: n
  "o" ->Enter trim method (Inside/Outside) <I>: o
  "y" ->Skip topology objects? (Yes/No) <Y>: y
  "y" ->Retain object data? (Yes/No) <Y>: y
  "i" ->Enter non edge object handling method (Delete/Reference/Ignore) <I>:i
  "y"->Objects outside the trim boundary not on frozen or locked layers will be trimmed or deleted.  Proceed? (Yes/No) <Y>:


Arguments is different when you cutting Outside or Inside polygon, be careful.

PS.
Set system variable CMDDIA to 0 and then call command MAPTRIM from command line, you will see :)

CHulse

  • Swamp Rat
  • Posts: 504
Re: MAPTRIM via lisp?
« Reply #4 on: November 02, 2015, 08:26:07 AM »
Awesome, thank you.
It never occurred to me to try turning CMDDIA off.
Cary Hulse
Urban Forestry Manager
Wetland Studies and Solutions

Civil 3D 2020 & 2023

CHulse

  • Swamp Rat
  • Posts: 504
Re: MAPTRIM via lisp?
« Reply #5 on: November 02, 2015, 10:16:55 AM »
Will C:EXTRIM work for you (from Express Tools)?

I considered that. It seemed to run much slower and wasn’t as clean. MAPTRIM allows me to use the last query boundary and that fits my specific workflow perfectly.
Thx
Cary Hulse
Urban Forestry Manager
Wetland Studies and Solutions

Civil 3D 2020 & 2023