delphi中如何在不关闭和打开数据集的情况下刷新dbgrid?
我需要不断地实时刷新 dbgrid。关闭和打开数据集工作正常,但会闪烁 dbgrid。我可以做什么来避免这种情况?
我想要一个像 Ajax 这样的解决方案,只更新必要的内容。
谢谢
I need to refresh dbgrid constantly, in real time. Close and open dataset works fine, but blink the dbgrid. What can I do to avoid this?
I'd like a solution like Ajax, that update only the necessary.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
您是否尝试过使用Disable- &启用控件?
此外,应该可以只调用 DataSet.Refresh 而不是关闭和打开来获得相同的结果。
Have you tried to use Disable- & EnableControls?
Furthermore, it should be possible to just call DataSet.Refresh instead of closing and opening to get the same result.
我在我的应用程序中使用它
上面的代码位于名为actRefreshData的
action
中,在ActionManager
中当我需要使用时我只需这样调用它
希望这有帮助。
提示:您可以添加一个
计时器
并自动执行此操作I use this in my app
The above code is in an
action
named actRefreshData, in theActionManager
When I need to use I just call it like
Hope this helps.
Hint: you can add a
Timer
and automate this看这里:
Look here: