在运行时调整标签控件的大小 [英] Resizing a label control at runtime

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

问题描述

最简单的方法是什么?我正在创建一个布局设计器类型的应用程序


谢谢

John

What is the easiest way to do this? I''m creating a layout designer type application

Thanks
John

推荐答案

您好Jcrouse,


您可以在运行时设置所有属性,使标签大小为

井。


当你想知道怎么做时,只需打开设计师生成的代码,即b $ b代码,它大部分直接显示。过了一段时间,你学习的东西比什么是
,因为那是永远适合的。


然而,永远不要求最好的在这个新闻组中,来自VB.net的优点是,没有一个最好的。方法所以没有人可以给你

那个。


但是有很多好方法和坏方法


:-)


我希望这有帮助吗?


Cor
Hi Jcrouse,

You can set allmost all properties at run time so the size of a label as
well.

And when you want to know how to do it, just open the designer generated
code, that shows it mostly direct. After a while you learn than what is
unneccessary in that because that is made to fit always.

However ask never for the "best" method in this newsgroup, the advantage
from VB.net is that there is not one "best" method so nobody can give you
that.

However there are a lot of good methods as well as bad methods

:-)

I hope this helps?

Cor


好点科尔。让我再补充一点。我希望能够用鼠标控制其位置和尺寸。同样,只有在运行时才能在设计器中执行此操作。我知道如何在代码中直接更改它。我也知道如何将顶部,左侧,高度和宽度写入XML以保存设计。我只是想不出第一部分


谢谢

John
Good points Cor. Let me add a little more. I want to be able to control ther location and sizing with the mouse. THe same way you would do it in the designer only at runtime. I know how to change it directly in the code. I also know how to write out the top, left, height and width to an XML for saving the design. I just can''t figure out the first part

Thanks
John


嗨Jcrouse ,


我曾经做过这个样本,问题的解决方案就在其中,虽然这个

更多,请查看。 (这是一个小样本)

http://www.google.com/gr************ .. .TNGP09.phx.gbl


我希望这有帮助吗?


Cor
Hi Jcrouse,

I once made this sample, the solution to your problem is in it although this
is more, have a look for it. (It is a small sample)

http://www.google.com/gr************...TNGP09.phx.gbl

I hope this helps?

Cor


这篇关于在运行时调整标签控件的大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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