我正在使用下面的模板来显示模态表单
Using tempForm As New CustomForm
'Do Something
StaticClass.StaticMemeber = tempForm
tempForm.ShowDialog
End Using
'I can still access the properties of tempForm here
MsgBox(StaticClass.StaticMemeber.Text)
'However this below returns True
MsgBox(StaticClass.StaticMember.IsDisposed)
Public Class StaticClass
Public Shared StaticMember as Control
End Class
有人可以帮我理解为什么会这样。谢谢。