- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I have installed on my machine both Map 3D and Civil 3D.
I have created a dll that i want to run it in both.
I want to avoid creating 2 separate dlls - one for map one for civil.
The command basically is selecting an entity and reads the property of it.
The type of entity is either a polyline or a civil3d alignment.
so if i load the dll in map 3D i want to ignore code about the civil 3D alignment.
in order to do that i have to detect what autocad i am into.
also if is map 3D i need to drop civil 3d references.
can someone help me?
Autodesk.AutoCAD.EditorInput.PromptEntityResult cl_res;
Autodesk.AutoCAD.EditorInput.PromptEntityOptions cl_prompt;
cl_prompt = new Autodesk.AutoCAD.EditorInput.PromptEntityOptions("\nSelect the centerline:");
cl_prompt.SetRejectMessage("\nSelect a polyline!");
cl_prompt.AllowNone = true;
cl_prompt.AddAllowedClass(typeof(Autodesk.AutoCAD.DatabaseServices.Polyline), false);
cl_prompt.AddAllowedClass(typeof(Autodesk.Civil.DatabaseServices.Alignment), false);
Thanks
Solved! Go to Solution.