Author Topic: Equivalent of Flatshot command in .Net API  (Read 4871 times)

0 Members and 1 Guest are viewing this topic.

rom1_am

  • Guest
Equivalent of Flatshot command in .Net API
« on: August 23, 2012, 09:54:07 AM »
Hi,

My need is to export a list of 3d solid contained in different blocks as if i was using the flatshot command (with the front view, and if possible in dxf format)

I've researched on the forum and found those topics:
http://www.theswamp.org/index.php?topic=36283.15
http://www.theswamp.org/index.php?topic=33105.msg385443#msg385443

Apparently it's not possible to use sendcommand with the flatshot command since we can't avoid the dialogbox.
Isn't there an equivalent of this command in the .net API?
(I use AutoCAD 2013 and C# with Visual studio express 2010)

I've also tried to understand how the 'dxfout' method works but didn't achieve to make it works.

Thanks for your help

zoltan

  • Guest
Re: Equivalent of Flatshot command in .Net API
« Reply #1 on: August 23, 2012, 11:13:32 AM »
I use the Section object to create 2D views of 3D objects.  The objects don't have to intersect the section plane.

rom1_am

  • Guest
Re: Equivalent of Flatshot command in .Net API
« Reply #2 on: August 24, 2012, 05:25:43 AM »
Thanks I'll try this possiblity.

rom1_am

  • Guest
Re: Equivalent of Flatshot command in .Net API
« Reply #3 on: August 29, 2012, 04:40:17 AM »
We've effectively done what we wanted thanks to the GetSection method on the different solid3d objects.

Code - C#: [Select]
  1. Plane plane = new Plane(Point3d.Origin, Vector3d.YAxis);
  2. using (Region region = solid.GetSection(plane))
  3. {
  4.    ...
  5. }
  6.  
(special thanks to Gile)

insmur

  • Mosquito
  • Posts: 2
Re: Equivalent of Flatshot command in .Net API
« Reply #4 on: June 29, 2019, 02:57:24 PM »
Could you share all code;