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

Is there any metthod to run timer tick event when form is hidden in c#.net

hi,

I am developing a window application using c#.net.

In the main MDI Form i used a timer, and in timer's tick event i have done some neccessary work.

In this form I also used notifyicon to put application in system tray on minimize, It needed to hide the Form (just like yahoo msgr/google talk).

when application is in maximize state Timer work properly whether it is focused or not, but if application is minimize in system tray, Timer on the form does not work.

I any body know how to run timer event when form is hidden plz suggest.

Jitendra Kumar
Programmer
Protatech India Pvt. Ltd.
May 30 '07 #1
5 7524
Hi
can you please help me telling how to write a program which would nitify the no of issues from tool using the notifyicon
Nov 3 '08 #2
Plater
7,872 Expert 4TB
I have never heard of this issue, nor have I ever run into it.
My timers function fine regardless of whether they are hidden/visible, minimized/maximized/whatever.
Nov 3 '08 #3
joedeene
583 512MB
How are you hiding your form? As Plater said, I don't think it matters how your FormState is, but are you changing your timers interval property or enabled property on the hiding event? That could be a problem, or maybe some properties you need to see a form, like the following...

Expand|Select|Wrap|Line Numbers
  1.  int mynumber = 0;
  2.         private void timer1_Tick(object sender, EventArgs e)
  3.         {
  4.  
  5.             mynumber++;
  6.             numericUpDown1.Value = mynumber;
  7.  
  8.         }
You would need the form to be shown rather than not visible to show the numericUpDown control. Although, that's an example you could be using things that don't require the Form's view...

joedeene
Nov 3 '08 #4
Hey Jitendra Kumar,

Did you manage to fix this? I run into the same issue
Oct 31 '17 #5
Frinavale
9,735 Expert Mod 8TB
Hi RobbieVdh,

I have never run into this problem either; that being said, I don't know what type of application you have developed or if there is some sort of odd restriction on timers within it.

Most of my timers are in a dynamic linked library (DLL) that retrieve information from a central database to update in memory objects that then raise Property Changed Notification events to let projects referencing it update accordingly (whether that be in another object or at the GUI).
Nov 6 '17 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

13
by: Manuel Lopez | last post by:
I have a puzzling form timer problem that I didn't experience prior to Access 2003 (though I'm not sure access 2003 is to blame). Here's the situation: a computer has two access 2003 databases on...
7
by: J. Hill | last post by:
I have a Windows Service with a timer but the .Tick event is not being fired/called. Don't know what code to include...I enabled and started the timer...I have the exact same code in a Windows...
4
by: Woody Splawn | last post by:
I have a Yellow text box on a winform that normally stays hidden but on occasion I make it visible to display some message to the user. In one particular case it would be nice if the text box...
7
by: Noozer | last post by:
I have a timer on a form. It isn't firing at all. I know that the timer is enabled, and that the interval is low (4000, which should be 4 seconds). To ensure the timer wasn't being inadvertantly...
4
by: Dan | last post by:
Hi, I have a timer on a form (System.Windows.Forms.Timer - Framework 1.1) that is set to 60 seconds as sort an of inactivity monitor. If 60 seconds have elapsed without any user activity I want...
5
by: Tony Gravagno | last post by:
I have a class that instantiates two Timer objects that fire at different intervals. My class can be instantiated within a Windows Form or from a Windows Service. Actions performed by one of the...
11
by: Hotrod2000 | last post by:
I'm quite new to programming but I'm having problems getting a timer to work in visual studio.net I've created a timer on a form, enabled it and then typed the following code (from the mdsn...
16
by: Peter Oliphant | last post by:
Note that although this involves SAPI, it is more a question about Timers and event handlers. I wrote a Speech Recognize handler (SAPI), and put some code in it to enable a Timer. It would not...
3
by: Steve | last post by:
Hi All I am using VB.net 2008 and use timer controls within my applications Question Does the code in a Timer control.tick event run on a different thread to the main Application thread (UI...
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: 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: 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
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
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
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.