[V8i C#] Highlight reference file with red color

Hi all,

If I open a Microstation DGN file from ProjectWise, if a reference file has been deleted from ProjectWise it is highlighted with red color and the File Name is changed.

How can do the same in C# or C++? Which API should I use?

Thanks for your help.

Parents
  • If I open a Microstation DGN file from ProjectWise, if a reference file has been deleted from ProjectWise it is highlighted with red color

    That's a feature of MicroStation, not ProjectWise.  If a reference file is not found, or is found but a model in that file doesn't exist,  then the reference dialog hilights the attachment in red.

    How can do the same in C# or C++?

    Do the same as what?  Do you want to detect a missing reference?  Or, do you somehow want to influence the reference dialog?

    Which API should I use?

    You're using MicroStation V8i.  Available APIs include VBA, MDL (C) and the MicroStationAPI (C++).  If you want to use C# with that version of MicroStation then you will be calling VBA via an InterOp.

    The VBA documentation is delivered with MicroStation.  Look at the Attachment object.  It provides two properties that you may find useful: Attachment.IsMissingFile and Attachment.IsMissingModel.

     
    Regards, Jon Summers
    LA Solutions

    Answer Verified By: IronMonkey 

Reply
  • If I open a Microstation DGN file from ProjectWise, if a reference file has been deleted from ProjectWise it is highlighted with red color

    That's a feature of MicroStation, not ProjectWise.  If a reference file is not found, or is found but a model in that file doesn't exist,  then the reference dialog hilights the attachment in red.

    How can do the same in C# or C++?

    Do the same as what?  Do you want to detect a missing reference?  Or, do you somehow want to influence the reference dialog?

    Which API should I use?

    You're using MicroStation V8i.  Available APIs include VBA, MDL (C) and the MicroStationAPI (C++).  If you want to use C# with that version of MicroStation then you will be calling VBA via an InterOp.

    The VBA documentation is delivered with MicroStation.  Look at the Attachment object.  It provides two properties that you may find useful: Attachment.IsMissingFile and Attachment.IsMissingModel.

     
    Regards, Jon Summers
    LA Solutions

    Answer Verified By: IronMonkey 

Children
No Data