M
Michaelov, Itzik
Hello
My very simple class C#:
[ComVisible(true)]
public class ClsStamCOMDLL
{
public ClsStamCOMDLL()
{
System.Windows.Forms.MessageBox.Show("Constructor");
}
~ClsStamCOMDLL()
{
System.Windows.Forms.MessageBox.Show("Finalize");
}
public void aaa()
{
System.Windows.Forms.MessageBox.Show("aaa");
}
}
Now i want use this class from VB6.
Add reference to created TLB
And following my VB6 project:
Dim a As StamCOMDLL.ClsStamCOMDLL
Set a = New StamCOMDLL.ClsStamCOMDLL
a.aaa
Set a = Nothing
The problem:
Why "~ClsStamCOMDLL()" method not fired ?
What about "a" object after set nothing
I fear memory leak...
Thanks
My very simple class C#:
[ComVisible(true)]
public class ClsStamCOMDLL
{
public ClsStamCOMDLL()
{
System.Windows.Forms.MessageBox.Show("Constructor");
}
~ClsStamCOMDLL()
{
System.Windows.Forms.MessageBox.Show("Finalize");
}
public void aaa()
{
System.Windows.Forms.MessageBox.Show("aaa");
}
}
Now i want use this class from VB6.
Add reference to created TLB
And following my VB6 project:
Dim a As StamCOMDLL.ClsStamCOMDLL
Set a = New StamCOMDLL.ClsStamCOMDLL
a.aaa
Set a = Nothing
The problem:
Why "~ClsStamCOMDLL()" method not fired ?
What about "a" object after set nothing
I fear memory leak...
Thanks