必须发生的计时器事件 [英] Timer events that must occur

查看:53
本文介绍了必须发生的计时器事件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近一直在玩一些UI想法,需要用户定时器

来驱动动画。我遇到的问题是Access经常停止

长时间点火计时器事件。


例如,用户输入一个字符另一个窗口,计时器

停止。用户键入另一个键,计时器再次启动,运行几秒钟,然后再次停止。


现在,代码我是写作很容易容忍一些丢弃的计时器事件

点火,但这些长时间停顿只是不起作用。


当然,一个ActiveX控件可能会做诀窍,但我也想限制使用外部控件,因为它会使软件更难部署,特别是对于快速演示等等,这需要b $ b。


有没有人有这个问题的聪明方法?

解决方案

2005年4月10日上午12:04,史蒂夫Jorgensen< no **** @ nospam.nospam>在新闻中写道

:h2 ******************************** @ 4ax.com:

我最近一直在玩一些UI想法,要求用户使用计时器来驱动动画。我遇到的问题是Access
会定期停止长时间触发计时器事件。

例如,用户在另一个窗口中键入一个字符,并且
计时器停止。用户键入另一个键,计时器再次启动,运行几秒钟,然后再次停止。

现在,我正在写的代码很容易容忍一些丢弃的计时器
事件发生,但这些长时间停顿只是不起作用。

当然,一个ActiveX控件可能会有所作为,但我也想限制使用外部控制,因为它使软件更难部署,特别是对于快速演示等。

有没有人有这个问题的任何聪明的解决方案?




SetTimer API,也许?需要一个回调函数,在较新版本的Access中不应该是一个

问题。


-

删除a 9通过电子邮件回复


On Sun,2005年4月10日15:33:26 -0000,Dimitri Furman< df ***** @ cloud99.net>

写道:

2005年4月10日上午12:04,Steve Jorgensen< no **** @ nospam.nospam>在新闻中写道
:h2 ******************************** @ 4ax.com:

我最近一直在玩一些UI想法,要求用户使用计时器来驱动动画。我遇到的问题是Access
会定期停止长时间触发计时器事件。

例如,用户在另一个窗口中键入一个字符,并且
计时器停止。用户键入另一个键,计时器再次启动,运行几秒钟,然后再次停止。

现在,我正在写的代码很容易容忍一些丢弃的计时器
事件发生,但这些长时间停顿只是不起作用。

当然,一个ActiveX控件可能会有所作为,但我也想限制使用外部控制,因为它使软件更难部署,特别是对于快速演示等。

有没有人有这个问题的任何聪明的解决方案?





难道不是吗?这不是多线程,VBA不支持
支持吗?


2005年4月9日星期六21:04: 27 -0700,Steve Jorgensen

< no **** @ nospam.nospam>写道:


我理解计时器的方式,一个ActiveX控件(我以为你是计划写一个计划的b $ b)可能无法解决问题。 WM_TIMER事件是由正常使用的
。定时器(SetTimer,VB中的Timer控件和

Access)并且它们是低优先级事件,只有在所有

其他事件被处理后才会发生。如果他们的时间已经过期,他们也可以合并为一个单独的事件

。在更改为tick之前。


多媒体计时器timeSetEvent更加可预测,但是消耗更多CPU资源的价格为




-Tom。

我'最近一直在玩一些需要用户定时器来驱动动画的UI想法。我遇到的问题是Access经常停止长时间触发定时器事件。

例如,用户在另一个窗口中键入一个字符,并且定时器
停止。用户键入另一个键,计时器再次启动,运行几秒钟,然后再次停止。

现在,我正在写的代码很容易容忍一些丢弃的计时器事件
解雇,但这些长时间停顿只是不起作用。

当然,一个ActiveX控件可能会有所作为,但我也想限制
使用外部控制,因为它使软件更难部署,特别是对于快速演示等。

有没有人有这个问题的任何聪明的解决方案?




I''ve recently been playing with some UI ideas that require the user of a timer
to drive animation. The problem I''m having is that Access routinely stops
firing timer events for long periods of time.

For example, the user types a character in another window, and the timer
stops. The user types another key, and the timer starts again, runs for a few
seconds, then stops again.

Now, the code I''m writing would easily tolerate a few dropped timer event
firings, but these long pauses just don''t work.

Of course, an ActiveX control might do the trick, but I also like to limit the
use of external controls because it makes the software harder to deploy,
especially for quick demos and such.

Does anyone have any clever solutions for this problem?

解决方案

On Apr 10 2005, 12:04 am, Steve Jorgensen <no****@nospam.nospam> wrote
in news:h2********************************@4ax.com:

I''ve recently been playing with some UI ideas that require the user of
a timer to drive animation. The problem I''m having is that Access
routinely stops firing timer events for long periods of time.

For example, the user types a character in another window, and the
timer stops. The user types another key, and the timer starts again,
runs for a few seconds, then stops again.

Now, the code I''m writing would easily tolerate a few dropped timer
event firings, but these long pauses just don''t work.

Of course, an ActiveX control might do the trick, but I also like to
limit the use of external controls because it makes the software
harder to deploy, especially for quick demos and such.

Does anyone have any clever solutions for this problem?



SetTimer API, perhaps? Needs a callback function, which shouldn''t be a
problem in newer versions of Access.

--
remove a 9 to reply by email


On Sun, 10 Apr 2005 15:33:26 -0000, Dimitri Furman <df*****@cloud99.net>
wrote:

On Apr 10 2005, 12:04 am, Steve Jorgensen <no****@nospam.nospam> wrote
in news:h2********************************@4ax.com:

I''ve recently been playing with some UI ideas that require the user of
a timer to drive animation. The problem I''m having is that Access
routinely stops firing timer events for long periods of time.

For example, the user types a character in another window, and the
timer stops. The user types another key, and the timer starts again,
runs for a few seconds, then stops again.

Now, the code I''m writing would easily tolerate a few dropped timer
event firings, but these long pauses just don''t work.

Of course, an ActiveX control might do the trick, but I also like to
limit the use of external controls because it makes the software
harder to deploy, especially for quick demos and such.

Does anyone have any clever solutions for this problem?



SetTimer API, perhaps? Needs a callback function, which shouldn''t be a
problem in newer versions of Access.



Shouldn''t it? Wouldn''t that amount to multi-threading, which VBA does not
support?


On Sat, 09 Apr 2005 21:04:27 -0700, Steve Jorgensen
<no****@nospam.nospam> wrote:

The way I understand timers, an ActiveX control (I''m thinking you are
planning on writing one) may not do the trick. WM_TIMER events are
used by the "normal" timers (SetTimer, the Timer control in VB and
Access) and they are low priority events, that only happen after all
other events are processed. They are also combined to a single event
if their time has expired before they got a change to tick.

The multimedia timer timeSetEvent ticks more predictably, but at the
price of consuming more CPU resources.

-Tom.

I''ve recently been playing with some UI ideas that require the user of a timer
to drive animation. The problem I''m having is that Access routinely stops
firing timer events for long periods of time.

For example, the user types a character in another window, and the timer
stops. The user types another key, and the timer starts again, runs for a few
seconds, then stops again.

Now, the code I''m writing would easily tolerate a few dropped timer event
firings, but these long pauses just don''t work.

Of course, an ActiveX control might do the trick, but I also like to limit the
use of external controls because it makes the software harder to deploy,
especially for quick demos and such.

Does anyone have any clever solutions for this problem?




这篇关于必须发生的计时器事件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆