web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

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

Time remaining value in progress bar

(0) ShareShare
ReportReport
Posted on by

Hi Experts,

I am using progress bar & only issue i have is that it shows incorrect time remaining. Please refer to pic & code below & suggest a fix so as to ensure that it shows correct time remaining values.

pastedimage1603985580562v2.png

protected  void processMyFile()
{
    SysOperationProgress importProgress = new SysOperationProgress();
    #AviFiles
    int cR,tR;

    importProgress.setCaption('Importing');
    importProgress.setAnimation (#AviTransfer);
    importProgress.setTotal(500);
    tR = my logic which gets total numbe of records;
        
    for (cR= 1; cR < tR ;cR  )
    {

        this.myImportProcess();
        importProgress.setText(strfmt('Importing record num %1 of total records to be imported %2',cR,tR));
        importProgress.setCount(counterOfRecordRows);
                    
    }// for ends

}

Thanks

Mav

I have the same question (0)
  • Verified answer
    Sergei Minozhenko Profile Picture
    23,093 on at

    Hi Mav,

    The estimated time is calculated based on the pace of count increment for progress. Maybe you can get a more precise time if you will use incCount method after each imported row instead of setCount.

    Also, why do you use constant 500 instead of real total count "tR" in SetTotal?

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 451 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 428 Super User 2025 Season 2

#3
BillurSamdancioglu Profile Picture

BillurSamdancioglu 239 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans