Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Answered

Go to the main table

(0) ShareShare
ReportReport
Posted on by 50

Hello, 

I created a two tables and I try to go to the main table from the form but it does not work. 

A first table is named TRI_NettingCorrelationAR with a field TRI_HFMCode. 

And a second table is named TRI_HFMCode with a field TRI_HFMCode. 

I triy to go to the main table from TRI_NettingCorrelationAR.TRI_HFMCode field in my form. 

I added jumRef method in the table TRI_NettingCorrelationAR  as below : 

public void jumpRef()

{
    TRI_HFMCode tri_HFMCode;
    Args args;
    MenuFunction menuFunction;
    ;
    tri_HFMCode = TRI_HFMCode::find(this.TRI_HFMCode);
    if (!tri_HFMCode)
    {
        return;
    }
    args = new Args();
    //Go to the Main Table FormGo to the Main Table Formadding
    //args.caller(tri_HFMCode);
    args.record(tri_HFMCode);
    menuFunction = new MenuFunction(menuitemdisplaystr(TRI_HFMCode),MenuItemType::Display);
    menuFunction.run(args);
}

But it does not work, I get an error on the line : 

menuFunction = new MenuFunction(menuitemdisplaystr(TRI_HFMCode),MenuItemType::Display);

The operand for the function is not an element.

Could you help please ? I do not know exactly if my way is right. 

Thanks a lot

  • mimi51340 Profile Picture
    50 on at
    RE: Go to the main table

    It was a mistake from my side. I had not created the menu item.

  • Gunjan Bhattachayya Profile Picture
    35,421 on at
    RE: Go to the main table

    Hi mimi,

    What is the menu item for this form? That will be available in the FormRef property.

  • mimi51340 Profile Picture
    50 on at
    RE: Go to the main table

    Hello, 

    So I created a specific form for THI_HFMCode Table as below:

    pastedimage1645774739543v1.png

    But from the FormRef property I cannot see it : 

    pastedimage1645775274973v1.png

    Any idea please ? 

    Thanks. 

  • Verified answer
    Gunjan Bhattachayya Profile Picture
    35,421 on at
    RE: Go to the main table

    Hi mimi,

    This should work without overriding jumpref method. Do you have FormRef property mentioned in TRI_HFMCode table? You can set this to "TRI_HFMCode" provided that is the menu item for the form for setting up the codes. Please make sure you have a relation defined between the tables as well.

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Jonas ”Jones” Melgaard – Community Spotlight

We are honored to recognize Jonas "Jones" Melgaard as our April 2025…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 294,165 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,968 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,158 Moderator

Leaderboard

Product updates

Dynamics 365 release plans