Popular Articles
Last viewed:
- C# Download File with Progress Bar
- Export GridView or Other Data as Microsoft Excel (CSV) File with C#
- Clustered Index vs. Non-Clustered Index in SQL Server
- Change Password Policy on Windows 2003 Server
- ASP.NET Download File to Web Browser
- Performance benchmarks for LINQ vs. SqlDataReader, DataSet - Selects: Part 1
Recent comments
- Awsome!!
7 hours 30 min ago - C# insert image
22 hours 23 min ago - jkll
3 days 10 hours ago - Thank You
4 days 10 hours ago - Another approach
6 days 11 hours ago - Issue
1 week 49 min ago - thanks
1 week 11 hours ago - Calendar date time
1 week 17 hours ago - Nice Explanation
1 week 21 hours ago - ramya
1 week 3 days ago

Possible fix
I think I found the problem here, it occurs when the progress percentage is cast from a double to an int. Replace:
int iProgressPercentage = (int)dProgressPercentage * 100);
with
int iProgressPercentage = (int)(Math.Round(dProgressPercentage) * 100);
And it seems to work much better! Hope this helps