switch on/off layer by code

Discuss and ask questions about CADViewX (Lite and Pro versions).

Moderators: SDS, support, admin

Post Reply
alfons
Posts: 6
Joined: 19 Jun 2007, 22:22
Location: Germany

switch on/off layer by code

Post by alfons » 20 Jun 2007, 10:47

Hallo,
how can i switch layers on/off by code using Delphi 7 ?

support
Posts: 3271
Joined: 30 Mar 2005, 11:36
Contact:

Post by support » 21 Jun 2007, 10:33

Hello!

Demo <b>Delphi</b> contains <b>unit</b> fLayers, where managing with layers is released. Calling <b>Layers</b> dialog is implemented by <b>btnLayers</b> SpeedButton. Please find in the demo the following lines:

Code: Select all

<b>procedure</b> TfmMain.btnLayersClick(Sender: TObject);
<b>begin
  if</b> FCADViewX.DXFImage <> <b>nil then
  begin</b>
    LayersDialogExecute(DXFImageSrv.DefaultInterface, FCADViewX);
    FCADViewX.RefreshAfterRotate;
  <b>end</b>;
<b>end</b>;
Demo <b>Delphi</b> is available in the ..\CADViewX\Demos\Delphi\.. folder after installation of <b>CADViewX Component</b> package.

Sergey.


Please post questions to the forum or write to support@cadsofttools.com

alfons
Posts: 6
Joined: 19 Jun 2007, 22:22
Location: Germany

Post by alfons » 21 Jun 2007, 12:14

Thanks for fast reply.

Post Reply