EBDN - Community - Question & Answers

  Tuesday, 08 December 2020
  1 Replies
  681 Visits
0
Votes
Undo
Hi Team,

i'm trying Update material & PreferredMaster for Cable Duct Device I'M using below Code its working fine but its showing warning message when we go for Generation of Drawing
Warning Message : "This Device has a representation in the layout diagram Review the layout Diagram to ensure proper Placement" Please help me on how to avoid this warning message programmatically.

ObjectItem Catalog_CableDuct = Get_DeviceFromCatalog(Helper.IEANCatalogProject);
if (CableDuctDevices != null && CableDuctDevices.Count > 0 && Catalog_CableDuct != null)
{
foreach (ObjectItem CableDuct in CableDuctDevices)
{
CableDuct.ReplaceBy(Catalog_CableDuct , true, ReplaceBehavior.WithPreferredMaster | ReplaceBehavior.Position | ReplaceBehavior.DontCheckNotUsed);
CableDuct.Store();
}
}