📄 5964.html
字号:
<html>
<head>
<title>请教 collection 清空问题</title>
</head>
<body bgcolor="#FFFFFF" vlink="#808080">
<center>
<h1>请教 collection 清空问题</h1>
</center>
<hr size=7 width=75%>
<hr size=7 width=75%><p>
Posted by Eric on September 24, 1998 at 10:25:20:<p>
如果我用了一个 Test 的外部 Collection 变数, 程式如下<br>当我于 Command1_Click 用后<br>于 Command2_Click 想清空 Collection<br>我需要 Set Test = Nothing 吗?<br>如果不 Set Test = Nothing ,会不会造成记忆体没有释放<p>Dim Test As New Collection<p>Private Sub Command1_Click()<br> Test.Add "aa"<br> Test.Add "bb"<br>End Sub<p>Private Sub Command2_Click()<br> Set Test = Nothing '需要吗?<br> Set Test = New Collection<br> Test.Add "bb"<br> Test.Add "cc"<br>End Sub<br>
<br>
<br><hr size=7 width=75%><p>
<a name="followups">Follow Ups:</a><br>
<ul><!--insert: 5964-->
<!--top: 6015--><li><a href="6015.html">Re: 请教 collection 清空问题</a> <b>小季</b> <i>14:01:33 9/25/98</i>
(<!--responses: 6015-->0)
<ul><!--insert: 6015-->
</ul><!--end: 6015-->
</ul><!--end: 5964-->
<br><hr size=7 width=75%><p>
</body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -