Method SetMeshTargetSize
SetMeshTargetSize(DocumentId, SmartReal)
Sets target size for a mesh of an analysis preparation document.
Declaration
[OperationContract]
[AvailableSinceVersion(7, 19, 15, 0)]
bool SetMeshTargetSize(DocumentId inDocumentId, SmartReal inTargetValue)
Parameters
| Type | Name | Description |
|---|---|---|
| DocumentId | inDocumentId | Identifier of the preparation document. |
| SmartReal | inTargetValue | Target size |
Returns
| Type | Description |
|---|---|
| bool | Whether mesh size has been changed. |
Remarks
This method is available since v7.19.
Examples
DocumentId docId = TopSolidHost.Documents.EditedDocument;
if (TopSolidHost.Application.StartModification("Change mesh Size", false))
{
try
{
SmartReal newSize = new SmartReal(UnitType.Length, 0.010);
TopSolidCaeHost.Documents.SetMeshTargetSize(docId, newSize);
TopSolidHost.Application.EndModification(true, true);
}
catch
{
TopSolidHost.Application.EndModification(false, false);
}
}