在netbeans中安装定时器组件?
我喜欢在 netbeans 中安装一个计时器组件,就像 Visual Studio 中 VB.net 的计时器组件一样,但我似乎在任何地方都找不到。
id like to install a timer component in netbeans much like the timer component for VB.net in visual studio but i can't seem to find one anywhere.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
有一些组件不能直接从 Netbeans 的组件窗格添加。即使我在不得不使用计时器时也遇到了同样的问题,但我没有办法找到一个。于是我开始自己写代码。用代码方法将计时器添加到应用程序中并不困难,因为它不需要窗口中的任何位置。您只需创建一个计时器对象并在代码中使用它,就这么简单。如果您需要知道如何创建计时器,可以查看 摆动计时器
--编辑--
我没有 Swing 计时器的工作示例,但下面的代码显示了 java util 计时器
--编辑 --
看看这个 链接
There are few components that cannot be added directly from the component pane of netbeans. Even i had the same problem when i had to work with the timers but there is no way for me to find one. So i started writing codes on my own. And its not hard to add timers into your application in code method as it does not need any location in the window. You just have to create a timer object and use it in your codes as simple as that. If you need to know how to create timers you can have a look at swing timers
--EDIT--
I dont have working example of swing timer but the code below shows the java util timer
--EDIT--
Have a look at this link