How to add a CADImageEnt?
Moderators: SDS, support, admin
-
- Posts: 1
- Joined: 15 Jun 2019, 07:22
How to add a CADImageEnt?
How to Add a CADImageEnt? Not use EntitiesCreator.
There is no code in AddEntityDemo.
who know?
Thanks!
Cristiano
There is no code in AddEntityDemo.
who know?
Thanks!
Cristiano
Re: How to add a CADImageEnt?
Hello,
AddEntities demo project contains the following code which shows how to add a CADImageEnt object.
Mikhail
AddEntities demo project contains the following code which shows how to add a CADImageEnt object.
Code: Select all
private void AddImageEnt()
{
string fileName = cnstImagePath;
if (!File.Exists(fileName))
{
fileName = cnstAddonPath + fileName;
if (!File.Exists(fileName))
return;
}
CADImageDef vImageDef = new CADImageDef();
vImageDef.FileName = fileName;
if (new Bitmap(vImageDef.FileName) != null)
{
AddEntToSection(ConvSection.ImageDefs, vImageDef);
CADImageEnt vImageEnt = new CADImageEnt();
vImageEnt.ImageDef = vImageDef;
vImageEnt.Point = new DPoint(180, 100, 0);
vImageEnt.UVector = CADConst.XOrtAxis;
vImageEnt.VVector = CADConst.YOrtAxis;
vImageEnt.Size = vImageEnt.ImageDef.Size;
vImageEnt.Width = 59;
if (!PlaceEntity(vImageEnt))
this.cadImage.Converter.ImageDefs.Remove(vImageDef);
}
}
Technical Support E-mail: support@cadsofttools.com
Chat support on Skype: cadsofttools.support
Chat support on Skype: cadsofttools.support