![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Jun 2004
Posts: 1
Rep Power: 0
![]() |
Good evening !
Who would help to indicate a possible problem that can be caused by the code sample, in the class below ?? How can you rewrite that code in order to solve that problem out ?? *************************** Class Individual Private Sub Save( ) 'Saves local data in a DataBase End Sub Sub Dispose( ) Save( ) End Sub Protected Overrides Sub Finalize( ) Dispose( ) MyBase.Finalize( ) End Sub End Class **************** Thanks so much, & very very nice Sunday ! MARIO ![]() |
|
|
|
|
|
#2 |
|
Newbie
Join Date: Sep 2004
Location: South Africa, Eastern Cape
Posts: 28
Rep Power: 0
![]() |
I think you need to make the following change to the last method, maybe. Because I think parents need to be called first before anything else is done when you overwrite
Protected Overrides Sub Finalize( ) MyBase.Finalize( ) Dispose( ) End Sub Not a hundred percent sure about this, but I think that is how it works.
__________________
Be vewwy vewwy quiet. I'm hunting wuntime ewwors. |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|