Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C#4.0
for every one hour i need a pop up form in Winforms with out using Windows services. how?
Posted 27-Dec-12 21:46pm
sai sagar1.9K
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

One of the possible variants is to use timer with time delay equals 1 hour.
the you must to subscribe to timer tick events and perform WinWorm display workflow.
  Permalink  
Comments
Sergey Alexandrovich Kryukov at 21-Jan-13 0:43am
   
Didn't you think that this request is a huge abuse of UI and... everything?
—SA
Oleksandr Kulchytskyi at 21-Jan-13 5:15am
   
Why abuse ? If i will be using System.Threading.Timer ,which performs counting on separate thread, so no overheads on UI thread. Furthermore, if we try to inject Rx to aforementioned approach and change existing behavior to push, with this approach we can extremely reduce some overheads to UI part.
 
Maybe you can advise some more advanced approach, i would like to hear it, because you have a spot and always have been giving nice advices =)
Sergey Alexandrovich Kryukov at 21-Jan-13 10:55am
   
I don't mean it. I mean design, treating the user with intrusive behavior, etc. Do you think the user can tolerate such application behavior? I would not. The whole idea is to abuse the user, don't you think so?
—SA
Oleksandr Kulchytskyi at 21-Jan-13 13:41pm
   
Ouhh, yep , from that point of view, you are completely right!
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

You can use Timer Control and can define time interval for 1 hour.
 
Create popup message and show it on Timer Tick event.
  Permalink  
Comments
sai sagar at 28-Dec-12 3:52am
   
is there any samples
Uma Shankar Patel at 28-Dec-12 3:56am
   
http://stackoverflow.com/questions/1142828/add-timer-to-a-windows-forms-application
sai sagar at 28-Dec-12 4:02am
   
ya its working. now i want in case of my application is closed then after one hr same pop will appear..
Uma Shankar Patel at 28-Dec-12 4:08am
   
Its only occurs when your application is running otherwise you need windows services.
there can be an alternative
if you don't want to show form to user. remove minimize maximize close button from form and form size 0,0 and run application.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Nirav Prabtani 284
1 OriginalGriff 217
2 Sergey Alexandrovich Kryukov 196
3 Mika Wendelius 185
4 CPallini 170
0 Nirav Prabtani 284
1 OriginalGriff 217
2 Mika Wendelius 185
3 _Amy 170
4 CPallini 170


Advertise | Privacy | Mobile
Web03 | 2.8.140721.1 | Last Updated 28 Dec 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100