Alex...thanks. After reading your recommendations, I 'simplified' and
"Alex Feinman [MVP]" <public_news@alexfeinman.com> wrote in message
news:eAS%23m55vEHA.2016@TK2MSFTNGP15.phx.gbl...
>I see what you mean. Of course using forms timer will not work if your form
>is busy initializing. And even Invoke from a thread will not either, since
>Invoke simply posts a message to the UI thread.
>
> I think that the problem witn menus might have something to do with the
> lack of UI idle time. One thing that comes to mind is to drop the
> animation thread priority at the end of the main form's load event (after
> the initialization is done)
>
> --
> Alex Feinman
> ---
> Visit
http://www.opennetcf.org > "Glyn Meek" <gjmeek@earthlink.net> wrote in message
> news:mWdhd.309$O11.88@newsread3.news.pas.earthlink.net...
>> Alex...I had considered this, but worried that merely using a timer event
>> (rather than a separate thread) would NOT allow me to refresh images on
>> my main form as no event would occur to redraw the form! Is this NOT the
>> case?
>>
>> I found the mechanism I am using at
>>
>>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetcomp/html/casoast.asp
>>
>>
>> Regards
>>
>> Glyn
>>
>>
>> "Alex Feinman [MVP]" <public_news@alexfeinman.com> wrote in message
>> news:%23MLj644vEHA.3908@TK2MSFTNGP12.phx.gbl...
>>> Don't see anything obviously wrong, but perhaps a better approach would
>>> be to do animation on a timer event (Forms.Timer as opposite to
>>> System.Threading.Timer). This is by the way what OpenNETCF Animation
>>> control is doing (hint, hint)
>>>
>>> I assume whatever you do right now to animate your graphics is done with
>>> Control.Invoke in mind
>>>
>>> --
>>> Alex Feinman
>>> ---
>>> Visit
http://www.opennetcf.org >>> "Glyn Meek" <gjmeek@earthlink.net> wrote in message
>>> news:Gs8hd.13912$KJ6.11758@newsread1.news.pas.earthlink.net...
>>>> 1) I have an 'animated' graphic window that displays as the application
>>>> is loading and doing its initialization. This animation routine is
>>>> staretd as a separate thread at the beginning of the Mainform load.
>>>> 2) The animation form is smaller than the screen and so overlays the
>>>> main application window.
>>>> 3) Rather than have the animation thread terminate when the main
>>>> application has finished loading/initializing, I want to have it
>>>> terminate when a user selects a menu item from the main application and
>>>> goe off to do the appropriate application programming.
>>>> 4) Everything appears to work well, in that the animation 'animates'
>>>> (!), the main application loads and initializes, and the main
>>>> application form displays under the animation window and all the menu
>>>> items appear...
>>>> ...but
>>>> 5) None of the main application form menu items appear to be 'live'.
>>>>
>>>> My intention is that the first action taken when one selectes a main
>>>> application menu item is to 'kill' the animation thread, but I cannot
>>>> get to that point if I cannot recognize a menu click event on the main
>>>> application form..
>>>>
>>>> Now, I realize that multithreading has a number of 'gotchas', but I
>>>> cannot figure out what I am a) not doing or b) am trying to do but am
>>>> not allowed to do.
>>>>
>>>> Anyone help?
>>>>
>>>> Regards
>>>>
>>>> Glyn Meek
>>>>
>>>
>>>
>>
>>
>
>