Locale that you are using?
Try it with Spanish localization.
I think the progress bar is interpreting of 10,23 as 1023
If I do the test with American location if I work.
My message is not to ask for a solution (and I've found the solution by rounding the value.) was only an appreciation for I have lost a lot of time until I find the reason.
progress.SecondaryTotal = datatable.Rows.Count;
foreach (DataRow row in datatable.Rows)
double porcentage = ((double)NumReg / (double)datatable.Rows.Count) * 100;
progress.SecondaryValue = NumReg;
progress.SecondaryPercent = Math.Round(porcentage, 0);
thank you very much