Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 Community / Forums / Finance forum / Extend UIBulider clas...
Finance forum
Suggested answer

Extend UIBulider class in standard SSRS report to add lookup control

Posted on by 739
Hi Everyone,
 
   I need to extend UIbuilder standard class to add a lookup control to the dialog for the SSRS report, do you know any suggestions on this code. 
 
[ExtensionOf(classStr(CustAccountStatementExtUIBuilder))]
final class CustAccountStatementExtUIBuilder_LeonardChesire_Extension
{
    private DialogField VEL_ServiceNameLookUp;
        public void build()
    {
        next build();
        VEL_ServiceNameLookUp = this.bindInfo().getDialogField(this.dataContractObject(),
            methodStr(CustAccountStatementExtContract, parmvEL_ServiceName));  
        
        VEL_ServiceNameLookUp.registerOverrideMethod(methodStr(FormStringControl,lookup),methodStr(CustAccountStatementExtUIBuilder,PerfServiceTypeLookup),this);
    }
 
Moreover, how can I show/hide this lookup control based on the menuitemoutput name called the report.

Thanks,
H
 
  • Hisham Alsayed Profile Picture
    Hisham Alsayed 739 on at
    Extend UIBulider class in standard SSRS report to add lookup control
    Hi Waed,
     
        Thanks for your reply it solved my problem.
     
    Thanks,
    H
  • Hisham Alsayed Profile Picture
    Hisham Alsayed 739 on at
    Extend UIBulider class in standard SSRS report to add lookup control
    Hi Waed,
     
     
        Did you try this code and works well or it is just suggestion.
     
    Thanks,
    H
  • Waed Ayyad Profile Picture
    Waed Ayyad 5,169 Super User 2024 Season 2 on at
    Extend UIBulider class in standard SSRS report to add lookup control
     
    Did my answer help you? If yes please verify it. Do you want additional help?
     
     
    Thanks,
    Waed Ayyad
  • Layan Jwei Profile Picture
    Layan Jwei 6,882 Super User 2024 Season 2 on at
    Extend UIBulider class in standard SSRS report to add lookup control
    Hi Hisham,

    What do you mean by "do you know any suggestions on this code"?  Are you facing any issues with this code u wrote?

    As for the 2nd question about showing or hiding lookup control, i think it was answered in your previous question:
    https://community.dynamics.com/forums/thread/details/?threadid=5116af78-35dd-ee11-904d-000d3a574bff

    Thanks,
    Layan Jweihan
    Please mark this answer as "Verified" if it solved your issue. In order to help others who will face a similar issue in the future
  • Suggested answer
    Waed Ayyad Profile Picture
    Waed Ayyad 5,169 Super User 2024 Season 2 on at
    Extend UIBulider class in standard SSRS report to add lookup control
     
    Try this code:
     
    if(this.controller().parmArgs().menuItemName() == menuItemOutputStr(MenuItem1))
    {
          VEL_ServiceNameLookUp.visible(false); 
    }
    else if(this.controller().parmArgs().menuItemName() == menuItemOutputStr(MenuItem2))
    {

         VEL_ServiceNameLookUp.visible(true);
    }
     
    Thanks
    Waed Ayyad
    If this helped, please mark it as "Verified" for others facing the same issue
     

Helpful resources

Quick Links

Dynamics 365 Community Update – Sep 9th

Welcome to the next edition of the Community Platform Update. This is a weekly…

Announcing Our 2024 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,277 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,135 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans