14588.html

来自「VB技巧问答10000例 VB技巧问答10000例」· HTML 代码 · 共 27 行

HTML
27
字号
<html>
  <head>
    <title>VB6 的做法</title>
  </head>
  <body bgcolor="#FFFFFF" vlink="#808080">
    <center>
      <h1>VB6 的做法</h1>
    </center>
<hr size=7 width=75%>

<hr size=7 width=75%><p>
Posted by <a href="mailto:sephiroth@optimasoft.com.tw">Sephiroth</a> on June 24, 1999 at 17:20:30:<p>
In Reply to: <a href="14563.html">Re: 如何用程式产生多个Label?</a> posted by South Wind on June 24, 1999 at 09:20:32:<p>
VB6 动态建立控制项的方法:<p>Private WithEvents mobjLabel As VB.Label<p>Private Sub Form_Load()<br>    Set mobjLabel = Controls.Add("VB.Label", "Label1")<br>    With mobjLabel<br>        .Caption = "Label1"<br>        .Move 0, 0, 1500, 300 <br>        .Visible = True<br>    End With <br>End Sub<p>动态建立的控制项可以是任意控制项, 只要不把 TypeLib 打错就行了. 当然 UserControl 也可以<br>动态建立, 但是要注意, 如果 UserControl造不出来就必须把 Alt-P-E Upgrade ActiveX Controls<br>的选项取消.
<br>
<br><hr size=7 width=75%><p>
<a name="followups">Follow Ups:</a><br>
<ul><!--insert: 14588-->
<!--top: 14605--><li><a href="14605.html">Re: VB6 的做法 (更正)</a> <b>Sephiroth</b> <i>09:00:31 6/25/99</i>
(<!--responses: 14605-->0)
<ul><!--insert: 14605-->
</ul><!--end: 14605-->
</ul><!--end: 14588-->
<br><hr size=7 width=75%><p>

</body></html>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?