473,394 Members | 1,781 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,394 software developers and data experts.

Concurrent routines

I want to make Label constantly blinks every time another routine is performed. Can you tell me how?
Nov 20 '05 #1
4 1042
Cor
Hi Amjad,

I think the best to do that is using a system.windows.form.timer
(You can drag that from the standard toolbox)

When you start your procedure you enable it.
And at the end you disable it.

Then in the event from that timer you do something as
\\\
If Label1.ForeColor.ToString = Color.Red.ToString Then
Label1.ForeColor = Color.Black
Label1.BackColor = Color.Red
Else
Label1.ForeColor = Color.Red
Label1.BackColor = Color.Black
End If
///
I hope this helps?

Cor


"Amjad" <an*******@discussions.microsoft.com> schreef in bericht
news:67**********************************@microsof t.com...
I want to make Label constantly blinks every time another routine is

performed. Can you tell me how?
Nov 20 '05 #2
* "=?Utf-8?B?QW1qYWQ=?=" <an*******@discussions.microsoft.com> scripsit:
I want to make Label constantly blinks every time another routine is performed. Can you tell me how?


You can place a timer control ('System.Windows.Forms.Timer') on your
form. Set its interval property and add appropriate code for the "blinking"
label to its 'Tick' event handler. Then enable the timer before caling
the procedure and disable it after it finishes.

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Nov 20 '05 #3
Hi Cor
Thanks for your reply
I tried doing the code you suggested and it didn't work as I would like to be
The Label doesn't blink until the procedure finishes its calculations, although the timer was enabled at the beginning of the procedure
It seems to me that the Tick event is not fired when the form is busy doing something else
I guess I can re-phrase my question as: How can I run two loops at the same time (concurrent, not nested loops)

Any other ideas

Amjad
Nov 20 '05 #4
Cor
Hi Amjad,

The answer is simple,

Put somewhere in that procedure
application.doevents

If it is a one sentence procedure, you should have to make an extra thread
wherein you put that procedure. The timer should stay on the form because
you cannot get easy on a windowform from a thread.

But that is a lot of work for a blinking label.

I hope this helps?

Cor

"> Hi Cor,
Thanks for your reply.
I tried doing the code you suggested and it didn't work as I would like to be. The Label doesn't blink until the procedure finishes its calculations, although the timer was enabled at the beginning of the procedure. It seems to me that the Tick event is not fired when the form is busy doing something else! I guess I can re-phrase my question as: How can I run two loops at the same time (concurrent, not nested loops) ?
Any other ideas?

Amjad

Nov 20 '05 #5

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

Similar topics

11
by: Durai | last post by:
Hi All, I tested "concurrent testing" in MySQL. It works fine. But I couldn't do in PostgreSQL 7.3.4 on HPUX IPF. I got deadlock problem. I used the PHP script to update table( one script...
2
by: spshealy | last post by:
Anybody know when DB2 is going to support Concurrent I/O on Aix... I heard it was coming but I don't know when? Thanks Scott
0
by: Volkan Arslan | last post by:
------------------------------------------------------------- LASER Summer School on Software Engineering Software engineering for concurrent and real-time systems Elba, Italy September 11 -...
6
by: roblugt | last post by:
I have what I imagine is a well-known .Net networking problem, but even though I've Googled for some time I've not yet come across a thread where this has been fully explained... There is a...
2
by: runner7 | last post by:
Can anyone tell me if there is a way in PHP to determine when a session times out on the server or how many concurrent sessions there are in your application?
2
by: mktselvan | last post by:
Hi, Existing running oracle application 11i (11.5.8) Database version is 8.1.7.4 There is any command / way to know the number of concurrent users for this application. ...
0
by: Gerardo Herzig | last post by:
Hi all. Im having some "problems" with a small concurrent plpython function. Based on a small example about concurrent programming, there is some code which works fine under python: #!...
3
by: =?Utf-8?B?RGFuaWVs?= | last post by:
Hi, I have a winform client which consumes a WCF service. I have a single service client(proxy) at the winform side, but spread the service calls into multiple threads so that they can do works...
0
amitpatel66
by: amitpatel66 | last post by:
There is always a requirement that in Oracle Applications, the Concurrent Program need to be execute programatically based on certain conditions/validations: Concurrent programs can be executed...
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
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...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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
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
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...
0
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...

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.