Hello World for .Net
This is the brief tutorial to show you how to integrate the AnyCAD .Net 3D control to your project.
Note:
- Your .Net project platform may be set to "AnyCPU" by default, and you should set to x86 or x64 platform depending your development environment.
- You must make sure that your assembly DLL/EXE files are in the same directory as the directory of AnyCAD .Net SDK locates.
Step by Step
1. Add assembly DLLs
You need the following two assembly dlls to your project:
- AnyCAD.Foundation.Net.dll
- AnyCAD.Presentation.Net.dll
- AnyCAD.Exchange.Net.dll
2. Add the visualization control
Please reference the sample code of AnyCAD.Basic project.
''' public partial class FormMain : Form { // Render Control private AnyCAD.Presentation.RenderWindow3d renderView;
public FormMain()
{
InitializeComponent();
//
// Create renderView
//
var container = this.Panel2;
renderView = new RenderWindow3d();
renderView.Size = container.ClientSize;
renderView.Dock = System.Windows.Forms.DockStyle.Fill;
container.Controls.Add(m_RenderView); }
Now, you should see the following screen if everything works well after you build and run your application:
Video
This video shows the steps to integrate AnyCAD .Net component to your WinForm project: