Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
IsDisposed and Invoke
Message
De
20/06/2012 14:13:58
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Titre:
IsDisposed and Invoke
Versions des environnements
Environment:
VB 9.0
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01546464
Message ID:
01546464
Vues:
58
I have this method in a project:
        ' Wrapper for Invoke method that does not throw an exception after the object has been
        ' disposed while the calling method was running in a background thread
        Private Sub SafeInvoke(ByVal method As [Delegate], ByVal args() As Object)

            Try
                If Not IsDisposed Then Invoke(method, args)
            Catch x As ObjectDisposedException
            End Try

        End Sub
This works as is. If I move this code into another project, IsDisposed and Invoke are highlighted stating that they are not declared. Both projects contains the three references to the component that needs this. So, I am trying to understand why it works on one and not on the other one.

Anyone knows what this does and how to resolves this issue?
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform