Quantcast
Channel: Mentor Graphics Communities: Message List
Viewing all articles
Browse latest Browse all 4541

How to iterate through component via .NET(such as C#, in DxD or XDx)

$
0
0

Hi Guys,

 

     I'm trying to iterate through component via .NET, but it does not work.

     By using "COM Interop" , I got file named "Interop.ViewDraw.dll" .

     But the code segment below could not work at all:

 

 

     ViewDraw.ApplicationDxAppHandle = (ViewDraw.Application)System.Runtime.InteropServices.Marshal.GetActiveObject("ViewDraw.Application");

 

     ViewDraw.IVdSchematicSheetDocumentstempSSDDxAppHandle.SchematicSheetDocuments();   // tempSSD has counter, butCANNOTiterate through

     ViewDraw.IVdObjsDesignObjects = DxAppHandle.Query(ViewDraw.VdObjectTypeMask.VDM_COMP, ViewDraw.VdAllOrSelected.VD_ALL);   // CANNOTagain

 

     This problem has troubled me a few weeks, how can I fix it?

 

      Any hints are welcome!


Viewing all articles
Browse latest Browse all 4541

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>