Engineering

 View Only
  • 1.  Rhapsody API: addLink/addLinkToElement

    Posted Mon April 03, 2023 09:58 AM

    I try to create a link in Rhapsody using addLink() or addLinkToElement() API function but without success.
    Always I get DISP_E_TYPEMISMATCH error.
    I checked my parameters and they seem to be all valid : Part, Part, null, Port, Port.
    Have you already encountered this error ?
    Thank you for your help



    ------------------------------
    Christophe Blanchard
    ------------------------------


  • 2.  RE: Rhapsody API: addLink/addLinkToElement

    Posted Fri April 07, 2023 02:32 PM

    Hi Christophe,
    See https://www.ibm.com/support/pages/system/files/inline-files/$FILE/rhapsody_api_javadoc_84_1.pdf : 'addLinkToElement' p 383

    You need to create the relationship IRPRelation first, and also retrieve the recipient.
    Hope this help.
    Corinne



    ------------------------------
    Corinne Bacle
    IBM
    33169822801
    ------------------------------



  • 3.  RE: Rhapsody API: addLink/addLinkToElement

    Posted Fri April 07, 2023 02:32 PM

    See API Rhapsody documentation page 383 "addLinkToElement"

    First create the relationship  (IRPRelation) and retrive the recipient.

    Thanks @Fabrice Mendes  for your help !



    ------------------------------
    Corinne Bacle
    IBM
    33169822801
    ------------------------------



  • 4.  RE: Rhapsody API: addLink/addLinkToElement

    Posted Wed April 12, 2023 02:45 AM

    I've found my mistake : For assoc parameter, it was not null but nothing.



    ------------------------------
    Christophe Blanchard
    ------------------------------