Please, anyone could help to return the created object “Alignment”?
Change your methods return type from
ObjectId then return the
yeah, i have tried this and it’s give me some number “45353” like id … i need the real object the alignment.
Technically speaking ObjectId is the ‘real object’ as an ObjectId is an object from an OOP standpoint, but I’m guessing what you mean is you want the Alignment entity which the ObjectId refers to? If that is the case then the Civil3d API should have a method to obtain the element from the ObjectId; I’m not familiar with Civil3D nor its API however but if its similar to the RevitAPI then it will be something similar to this
var alignmentElement = doc.GetElement(alignmentObjectId);.
Civil 3D and Revit APIs are very different, please stop confusing people.
The issue is to return not the Civil 3D Alignment but rather the Dynamo wrapper of a Civil 3D Alignment.
You have many options:
Last, you need to use the return keyword in the definition of the node.
Thank you Thomas for your help appreciate it .