473,385 Members | 1,347 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

refreshing the screen

Art
I've got a program that I run -- it's under the control of a form. Part of
the process is fairly lengthy (10 minutes). The form has a control that lets
me know how far it's gotten.

My problem is that if I switch to, say, e-mail and then try to get back to
my form it will not appear until it finishes the lengthy step.. When I
update the control (with the status) I tell the form to refresh. Is there
something else I need to do so that I can switch away from the application
and then go back to it again and see the status?

I'd appreciate any suggestions.

Art
Nov 21 '05 #1
2 1520
The "easy" way is to call doevents regularly during your 10 minute process
(say, once per second, if possible).

Another way is to do your long running process in a background thread. Look
into the Thread class. Here's an example from another post:

http://groups.google.com/groups?q=sw...phx.gbl&rnum=1

"Art" <Ar*@discussions.microsoft.com> wrote in message
news:B5**********************************@microsof t.com...
I've got a program that I run -- it's under the control of a form. Part
of
the process is fairly lengthy (10 minutes). The form has a control that
lets
me know how far it's gotten.

My problem is that if I switch to, say, e-mail and then try to get back to
my form it will not appear until it finishes the lengthy step.. When I
update the control (with the status) I tell the form to refresh. Is there
something else I need to do so that I can switch away from the application
and then go back to it again and see the status?

I'd appreciate any suggestions.

Art

Nov 21 '05 #2
Art
Scott,

Thanks -- the "easy way" seems to work for me. I put DoEvents in the same
step that updates my status control.

Art
Nov 21 '05 #3

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

Similar topics

1
by: edward hage | last post by:
The following program is an applet that reads a number from a file 10 times per second. It needs to be shown graphically. The file monitors a procesvariable and changes continuously. It is read...
1
by: sentinel | last post by:
Hello, I'm having problems refreshing a main window, and am not sure really whether the solution will be Javascript or PHP related. Firstly, I have a main file that calls a pop-up box which...
60
by: A.Translator | last post by:
I have been struggling with a page that is based on a table structure (because that is all I am feeling comfortable with at the moment) styled with css. One of the problems I run in to is Opera...
1
by: LRD | last post by:
Form not refreshing after autopostback unless keyboard or mouse move Hi, We created several new ASP.NET C# forms for our intranet. In each form we use panels for different sections of the...
1
by: Tom | last post by:
I have an ASP.NET web page coded in VB.NET (2003). That web page has a dropdown box on it which is loaded during the page_load event. When the user drops this down and selects a data item, the...
3
by: Ray Stevens | last post by:
I know there is a setting that will prevent screen flashing when refreshing a web page but cannot seem to find it. Can someone point me in the right direction?
4
by: Nikola Bucic | last post by:
I have a problem with picturebox. I'm drawing on it with picturebox.DrawString, picturebox.DrawRectangle, etc. and it's working fine. But when I open another window over it I lost that. Triggering...
6
by: Chris Moore | last post by:
I have a .NET form where I am updating a progress bar & counter. As long as the form never loses focus, everything on the form refreshs fine. But If I open another window (like Windows Explorer)...
0
by: lv2compute | last post by:
I am having a problem with my datagridview. I have a small table that has two columns. The first column is bound to my dataset. The second column is a combobox. I add items to the combobox based on...
10
by: Dan2kx | last post by:
hello, i have a quick question, is there anyway to speed up a listbox refreshing, its quite large with 18 columns and so far upto 30 rows, but it updates row by row every time the screen changes (ie...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

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.