Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics 365 | Integration, Dataverse...
Suggested answer

Relationship object in Xrm.Navigation.navigateTo

(0) ShareShare
ReportReport
Posted on by 45

I am trying to open at form and pre-populate a lookup field using Xrm.Navigation.navigateTo

This piece of code is being used to create the relationship, however it is not displaying anything.

        pageInput.relationship = {
            attributeName: "crd80_caseloadreview",
            navigationPropertyName: thisRecordName,
            name: "crd80_task_CaseLoadReview_crd80_caseloadreview",
            relationshipType: 0,
            roleType: 1
            }

  • attributeName: has been set to the logical field name on the form
  • navigationPropertyName: is the name of the record I wish to link to
  • relationshipType: is set to one to many
  • I dont really understand what "name" I should be using (have used the relationship name from the entity)
  • I dont really understand what "roleType" to use.

https://learn.microsoft.com/en-us/power-apps/developer/model-driven-apps/clientapi/reference/xrm-navigation/navigateto is not very informative.

  • Suggested answer
    a33ik Profile Picture
    a33ik 84,325 Most Valuable Professional on at
    RE: Relationship object in Xrm.Navigation.navigateTo

    Hello Martin,

    Can you please elaborate on your scenario? Am I right that you try to open the new record form and populate the lookup? In this case Xrm.Navigation.openForm is the better candidate for it - learn.microsoft.com/.../openform

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Congratulations 2024 Spotlight Honorees

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December

Congratulations to our December super stars! 🥳

Start Your Super User Journey

Join the ranks of our community heros! 🦹

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,703 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,433 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans