I have a class that I want to show the VB PowerPack Notification Window from, but the class doesn't have a form. I just want to show the window as it is running down its code. I saw a similar thread in another forum (the page on GotDotNet for the VB PowerPack) talking about the use of Delegates/Invoke. The code sample was in C++, so I tried to convert it to a VB.net equivalent. But, I can't get it to work. Here is what I have:
Public Class MyClass
Private NotificationWindow1 As VbPowerPack.NotificationWindow = New VbPowerPack.NotificationWindow
Private Delegate Sub DisplayNotification(ByVal strMessage As String)
Private Sub DisplayNotificationWindow(ByVal strMessage As String)
NotificationWindow1.Notify(strMessage, 3000)
End Sub
Public Sub MySubroutine
Dim NotificationWindow As DisplayNotification = AddressOf DisplayNotificationWindow
NotificationWindow.Invoke("My Message")
End Sub
End Class
Can anyone with more programming ability than myself lend a hand with this??
Question
Delsphynx
I have a class that I want to show the VB PowerPack Notification Window from, but the class doesn't have a form. I just want to show the window as it is running down its code. I saw a similar thread in another forum (the page on GotDotNet for the VB PowerPack) talking about the use of Delegates/Invoke. The code sample was in C++, so I tried to convert it to a VB.net equivalent. But, I can't get it to work. Here is what I have:
Can anyone with more programming ability than myself lend a hand with this??
Link to comment
Share on other sites
5 answers to this question
Recommended Posts