Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Answered

My system page is getting time to load.

Posted on by 200

Here I have a page where I get all the sales order sales order archive copied with copy management function(from sales order).

Due this my page is getting to much time to load, because on each time I do trigger OnOpenpage  the order gets displayed in my system page, may be due this it's taking time. How can we avoid this taking time, what is the solution please help very urgent.

Is there any function, or method I can use in al code to avoid this issue?

Screenshot_5F00_20230518_2D00_140143_5F005F00_01.jpg

  • Dividutt Profile Picture
    Dividutt 200 on at
    RE: My system page is getting time to load.

    Thankyou will look into this.

  • Suggested answer
    Nitin Verma Profile Picture
    Nitin Verma 21,091 Super User 2024 Season 1 on at
    RE: My system page is getting time to load.

    HI,

    I just saw your codeunit, and found that you have scope to optimize your code while inserting data in the enquiry table, you need to change your Primary Key of enquiry table, with say "Order No." and write below line while inserting, no need of else condition. I would request you, share always Txt of code.

    if not Enquiry.get(SalesHeader."No.") then

    begin

      enquiry.init

       .....................

      enquiry.insert

    end;

  • Suggested answer
    YUN ZHU Profile Picture
    YUN ZHU 73,696 Super User 2024 Season 2 on at
    RE: My system page is getting time to load.

    Hi, I suggest you move this code into an action and let the user run it manually.
    Or get data from Sales Order when opening your custom Enquires page, so at least it won't affect the standard functionality.

    Also, you can give Page Background Tasks a try.
    More details:

    https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/devenv-page-background-tasks

    https://businesscentralgeek.com/how-to-run-background-processes-in-business-central-page-background-tasks

    And, Performance Articles For Developers
    https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/performance/performance-developer

    Hope this helps.

    Thanks.

    ZHU

  • Dividutt Profile Picture
    Dividutt 200 on at
    RE: My system page is getting time to load.

    Hi Nitin Verma, Here is my codeunit ss where I code for copy all sales order to enquiry list page.

    3733.ss1.png 0363.ss2.png2620.ss3.pngss4.png

    and i call it on open page so I can see my copied sales order in enquiry, but there are more records its takes time so is there way, I can do so that it take less time.

    ss5.png_2D00_640x480.png

  • Suggested answer
    Nitin Verma Profile Picture
    Nitin Verma 21,091 Super User 2024 Season 1 on at
    RE: My system page is getting time to load.

    Please share your code.

  • Dividutt Profile Picture
    Dividutt 200 on at
    RE: My system page is getting time to load.

    Yes Nithin Verma due to openpage , but I want to show my orders in openpage only, partially ship or fully shipped all are updated on my page when I open it

    I tried using date function to show that months orders, so my question is there any way we can optimise code where my page can take less time?

  • Verified answer
    YUN ZHU Profile Picture
    YUN ZHU 73,696 Super User 2024 Season 2 on at
    RE: My system page is getting time to load.

    Hi, If you are using the latest version of BC, you can use the In-client performance profiler function to see which extension, trigger or function is causing this problem.
    More details: https://yzhums.com/23121/

    pastedimage1684453785346v1.png

    pastedimage1684453802299v2.png

    Hope this helps.

    Thanks.

    ZHU

  • Amit_Sharma Profile Picture
    Amit_Sharma 2,545 on at
    RE: My system page is getting time to load.

    Hi,

    First check, If you add flowfields in the list. this is also one reason to load the list page

    Regards

    Amit Sharma

    www.erpconsultors.com

    www.linkedin.com/.../

    Press Yes If info is useful

  • Suggested answer
    Nitin Verma Profile Picture
    Nitin Verma 21,091 Super User 2024 Season 1 on at
    RE: My system page is getting time to load.

    Share your code with trigger where you have written. and I think it will take this much time because you have written on OnOpenpage.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans