Results 1 to 14 of 14

Thread: [RESOLVED] Timers in VB.NET App for Windows Mobile

  1. #1

    Thread Starter
    Lively Member okosv's Avatar
    Join Date
    Sep 2006
    Posts
    95

    Resolved [RESOLVED] Timers in VB.NET App for Windows Mobile

    Hello all.
    I develop the application under Windows Mobile.
    There are 2 forms. In secondary form, I use timer.
    Then after several times, I close secondary form by
    Code:
    Me.Close
    .
    But timer not stopped, why?

    P.S. Sorry for my english.
    Last edited by okosv; Feb 26th, 2009 at 02:02 AM.

  2. #2
    ASP.NET Moderator gep13's Avatar
    Join Date
    Nov 2004
    Location
    The Granite City
    Posts
    21,963

    Re: Timers in VB.NET App for Windows Mobile

    Hey,

    This question might be best asked in the Windows Mobile Forum, you can find it here:

    http://www.vbforums.com/forumdisplay.php?f=70

    You should maybe ask a moderator to move this post to that forum.

    Gary

  3. #3

    Thread Starter
    Lively Member okosv's Avatar
    Join Date
    Sep 2006
    Posts
    95

    Re: Timers in VB.NET App for Windows Mobile

    ok, who is moderator of this forum?

  4. #4
    ASP.NET Moderator gep13's Avatar
    Join Date
    Nov 2004
    Location
    The Granite City
    Posts
    21,963

    Re: Timers in VB.NET App for Windows Mobile

    Hey,

    The Moderators for this Forum are RobDog888, kleinma. I am sure if you ask they will move the thread to the correct location.

    Gary

  5. #5
    KrisSiegel.com Kasracer's Avatar
    Join Date
    Jul 2003
    Location
    USA, Maryland
    Posts
    4,985

    Re: Timers in VB.NET App for Windows Mobile

    Make sure to stop the timer before closing the form. The timer may run in another thread (depends on what timer object you're using) so you should stop it when you no longer need it.

    Also, don't bother trying to PM a specific moderator; just report the thread and ask them to move it. I don't believe you can report your own threads (without some trickery, anyway) so I submitted one to have it moved.
    KrisSiegel.com - My Personal Website with my blog and portfolio
    Don't Forget to Rate Posts!

    Free Icons: FamFamFam, VBCorner, VBAccelerator
    Useful Links: System.Security.SecureString Managed DPAPI Overview Part 1 Managed DPAPI Overview Part 2 MSDN, MSDN2, Comparing the Timer Classes

  6. #6
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,929

    Re: Timers in VB.NET App for Windows Mobile

    Thread moved to "Mobile Development" forum


    Also, don't bother trying to PM a specific moderator; just report the thread and ask them to move it. I don't believe you can report your own threads (without some trickery, anyway) so I submitted one to have it moved.
    Exactly.

    Just ignore the word "Bad" on the report icon ( to the left of each post), and the warning that it is just for spam etc - use it any time that you think a thread needs moderator/admin attention.

  7. #7
    ASP.NET Moderator gep13's Avatar
    Join Date
    Nov 2004
    Location
    The Granite City
    Posts
    21,963

    Re: Timers in VB.NET App for Windows Mobile

    Good to know, I specifically didn't recommend that as I thought it was only for rude and abusive posts.

  8. #8
    Frenzied Member
    Join Date
    Oct 2005
    Posts
    1,286

    Re: Timers in VB.NET App for Windows Mobile

    Hi,
    disable the timer before closing, and if you are showing the form as a dialog, then remember to dispose of it.
    Pete Vickers
    MVP - Device Application Development
    http://www.gui-innovations.com http://mobileworld.appamundi.com/blogs/

  9. #9

    Thread Starter
    Lively Member okosv's Avatar
    Join Date
    Sep 2006
    Posts
    95

    Re: Timers in VB.NET App for Windows Mobile

    I did so (disable timers before closing).
    But why child timers not stop automatically, when parent form is closing?
    In VB6, when parent form closed, all child timers is automatically stopped.

  10. #10

    Thread Starter
    Lively Member okosv's Avatar
    Join Date
    Sep 2006
    Posts
    95

    Re: Timers in VB.NET App for Windows Mobile

    Quote Originally Posted by si_the_geek
    Thread moved to "Mobile Development" forum


    Exactly.

    Just ignore the word "Bad" on the report icon ( to the left of each post), and the warning that it is just for spam etc - use it any time that you think a thread needs moderator/admin attention.
    Thanks a lot. Shall be kept in mind.

  11. #11
    Frenzied Member
    Join Date
    Oct 2005
    Posts
    1,286

    Re: Timers in VB.NET App for Windows Mobile

    This is VB.Net though, not VB6

    So - is your problem solved?
    Pete Vickers
    MVP - Device Application Development
    http://www.gui-innovations.com http://mobileworld.appamundi.com/blogs/

  12. #12

    Thread Starter
    Lively Member okosv's Avatar
    Join Date
    Sep 2006
    Posts
    95

    Re: Timers in VB.NET App for Windows Mobile

    yes, thanks for all.

  13. #13
    KrisSiegel.com Kasracer's Avatar
    Join Date
    Jul 2003
    Location
    USA, Maryland
    Posts
    4,985

    Re: Timers in VB.NET App for Windows Mobile

    Quote Originally Posted by okosv
    I did so (disable timers before closing).
    But why child timers not stop automatically, when parent form is closing?
    In VB6, when parent form closed, all child timers is automatically stopped.
    This is because VB6 had no multi-threading support built in where as .Net has a large amount of support for it. Sure, there are ways to "hack-it" with VB6 but timers and such didn't really support it and just died with their parent object (your form).
    KrisSiegel.com - My Personal Website with my blog and portfolio
    Don't Forget to Rate Posts!

    Free Icons: FamFamFam, VBCorner, VBAccelerator
    Useful Links: System.Security.SecureString Managed DPAPI Overview Part 1 Managed DPAPI Overview Part 2 MSDN, MSDN2, Comparing the Timer Classes

  14. #14

    Thread Starter
    Lively Member okosv's Avatar
    Join Date
    Sep 2006
    Posts
    95

    Re: Timers in VB.NET App for Windows Mobile

    Quote Originally Posted by Kasracer
    This is because VB6 had no multi-threading support built in where as .Net has a large amount of support for it. Sure, there are ways to "hack-it" with VB6 but timers and such didn't really support it and just died with their parent object (your form).
    ok

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width