如何在vb.net中使用带有(datagridview)的进程条? [英] How to use process bar with (datagridview) in the vb.net ?

查看:165
本文介绍了如何在vb.net中使用带有(datagridview)的进程条?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在vb.net中使用(ProgressBar)和(datagridview)?



开始工作时(ProgressBar)和(datagridview)中的视图数据之后

How to use (ProgressBar) with (datagridview) in the vb.net ?

when beginning work (ProgressBar) and after view data in the (datagridview)

推荐答案

进程条?那是什么?



我想你正在引用一个进度条。但是,既然DGV没有报告任何进展,也没有处理任何东西,那么重点是什么?



你能做到的最好do是一个marquee类型的进度条,只显示正在发生的事情,而不是100%完成的时间或进度。您将启动进度条滚动,启动长时间运行的数据库操作以检索BackgroundWorker组件中的记录,并在操作完成时停止进度条。
"process bar"?? What''s that??

I think you''re refering to a progress bar. But, since the DGV doesn''t report progress of anything, nor does it "process" anything, what''s the point??

The best you can do is a "marquee" type progress bar that just shows something is happening, not the time or progress to 100% completion. You would start the progress bar scrolling, launch the long running database operation to retrieve the records in a BackgroundWorker component, and when the operation is complete, stop the progressbar.


如何在DataGridView中创建ProgressBar列 [ ^ ]



请参考以上链接。可能会帮到你。
How to Create ProgressBar Column in DataGridView[^]

Please refer above link. Might help you.


喜欢这个?



Like this?

progressBar1.Maximum = DatagridView1.RowCount 'Set Max Lenght
progressBar1.Step = 1 'Set Step
progressBar1.Value = 0 'Set Begin value

For line as integer = 0 to DatagridView1.RowCount - 1
    'Add your command / syntax
    progressBar1.Value = progressBar1.Value + 1 
Next


这篇关于如何在vb.net中使用带有(datagridview)的进程条?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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