标签滞后问题! ! ! [英] Lag problem with labels! ! !

查看:86
本文介绍了标签滞后问题! ! !的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨...



i有一个带有80个标签的表格..但显示它滞后..无论如何都要超越这个滞后问题以便表格打开清楚又快速?!!



谢谢!



我尝试过:



只是询问是否有可能或VB问题是否与这么多元素一起工作!!!

Hi...

i have a form with 80 labels..but on show it lags..is there anyway to overpass this lag problem so that the form opens clearly and fast?!!

Thanks!

What I have tried:

Just asking if is possible or if is VB problem working with so many elements!!!

推荐答案

这不是一个VB问题,并且80个标签不太可能(虽然对于单个表单而言太多,用户获得的信息太多而且通常不能正常工作)会导致显着的滞后他们自己的。我刚刚测试过,一个带有84个标签的表格,对我来说非常重要,在一台不那么先进的PC上。



我怀疑你是如何获得信息来填写减慢标签的标签,而不是标签本身。但我们无法帮助您,因为我们无法访问您的代码或用于获取标签文本的数据源。
It's not a "VB problem", and it's unlikely that 80 labels (though far too many for a single form, the user gets too much info and that doesn't generally work well) would cause significant "lag" on their own. I just tested, and a form with 84 labels on it loads pretty much immediately for me, on a much-less-than-state-of-the-art PC.

I'd suspect that it's how you are getting the info to "fill in" the labels that slows things down, not the labels themselves. But we can't help you there, as we don't have any access to your code or the data source you use to get the label text from.


您最好:



1.在装载之前使所有图像尺寸正确(调整大小花费宝贵的时间)



2。将所有图像合并为一个主图像 - 加载1个文件比加载80个文件快!



3.将图像从主图像中的位置变成形式



4.不使用80个标签而是使用单个UserControl和自定义渲染...



另一个处理图像的方法是 Windows窗体ImageList组件 [ ^ ](链接附带示例)
You're better off:

1. making all images the correct size before loading (resizing take valuable time)

2. combine all images into a single master image - loading 1 file is fast than loading 80!

3. Blitting the images from their position in the master image into the form

4. not use 80 labels and instead use a single UserControl and custom rendering...

Another method of handling images is the Windows Forms ImageList Component[^] (link comes with examples)


这篇关于标签滞后问题! ! !的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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