473,486 Members | 2,427 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Update progress bar to reflect database update?

Hi, I was wondering if anyone ever done a progress bar that reflects a
database update. I have an update query with SQL server that takes
about 5 minutes. I can't figure out a way to show the progress of the
update in a progress bar since I have no idea how much time it will
take. Anyone ever done this??
Nov 20 '05 #1
3 7780
Hi,

The dataadapter has the rowupdating, and rowupdated events. Maybe
you can use one of them to update a progressbar.

http://msdn.microsoft.com/library/de...iderevents.asp

Ken
---------------
"Pierre" <pi*****@hotmail.com> wrote in message
news:90**************************@posting.google.c om...
Hi, I was wondering if anyone ever done a progress bar that reflects a
database update. I have an update query with SQL server that takes
about 5 minutes. I can't figure out a way to show the progress of the
update in a progress bar since I have no idea how much time it will
take. Anyone ever done this??

Nov 20 '05 #2
Hi Pierre,

I do exactly what you're trying to do. I use the datatablerow_changed
event. First, create your pbar; then add this code before calling
performstep:
AddHandler dt.RowChanged, New DataRowChangeEventHandler(AddressOf
DataTableRow_Changed)

The code of the event is as follows:
Public Sub DataTableRow_Changed(ByVal Sender As Object, ByVal e As
System.Data.DataRowChangeEventArgs)

' The DataRow has changed. update pbar2

glf_icount += 1

If glf_icount > (pbar2.Maximum / 100) Then

glf_icount = 0

pbar2.PerformStep()

Application.DoEvents()

End If

glf_totalcount += 1

prglabel.Text = glf_totalcount

End Sub

HTH,

Bernie Yaeger

"Pierre" <pi*****@hotmail.com> wrote in message
news:90**************************@posting.google.c om...
Hi, I was wondering if anyone ever done a progress bar that reflects a
database update. I have an update query with SQL server that takes
about 5 minutes. I can't figure out a way to show the progress of the
update in a progress bar since I have no idea how much time it will
take. Anyone ever done this??

Nov 20 '05 #3
Thank you very much to you both, this is exactly what I need thanks again!
Nov 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
8191
by: Rich Wallace | last post by:
Hi all, I've been though many posts in this group and have yet to find one that helps me understand how to accomplish my goal. I have an XML document that stores user specific values that I...
3
2640
by: Brian Birtle | last post by:
**** A CHALLENGE TO THE GURUS - refute the statement "It's impossible to build a file upload progress meter using ASP.NET" **** First person to prove me wrong gets "All Time .NET Programming GOD"...
11
2226
by: Siv | last post by:
Hi, I seem to be having a problem with a DataAdapter against an Access database. My app deletes 3 records runs a da.update(dt) where dt is a data.Datatable. I then proceed to update a list to...
1
2523
by: erin.sebastian | last post by:
Hello Everyone, I have created a small application in vb.net to maintain items in a database the problem i am having is that once i delete/add/edit an individual item the changes don't reflect in...
3
1921
by: WB | last post by:
Hi, I'm building my first Windows application using C#. My Windows application sends newsletter to our subscribers by email. Our newsletter is sort of "customized" so my application has to...
30
3349
by: Charles Law | last post by:
Here's one that should probably have the sub-heading "I'm sure I asked this once before, but ...". Two users are both looking at the same data, from a database. One user changes the data and...
2
2923
by: Rico Schäpe | last post by:
Hi, I want to show a progress dialog for long working tasks. The task should be canceled too. Inspired by the article of Chris Sells "Safe, Simple Multithreading in Windows Forms, Part 2" I've...
2
2882
by: hotflash | last post by:
Hi Master CroCrew, I found a good PURE ASP that will allow you to upload 10MB file to the server and the file contents such as Network, Author, Title, etc... will insert to MS Access at the same...
6
4093
by: Garima12 | last post by:
There is a update panel,gridview and update progress. fetching the data from database and filling in gridview. at the time of processing update progress is working and showing processing........ My...
0
7100
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6964
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7126
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7175
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6842
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
1
4865
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3070
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
1
598
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
262
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.