I have written a class which has a Webview in it. (Needs WebView to be able to log into a password protected website using javascript. Figured out how with Warwound's help.)
Because it has a Webview in it, I cannot declare the class in the Process_Globals section of my service. So I am forced in a regular Sub to do something like:
Dim readReports as GetReports
readReports.Initialize(...)
readReports.PullFromWeb(Main.the_user,Main.the_password)
It works. But I am leaking memory. In a service, I call the class once an hour. Each time (checking the memory used) I can see memory being allocated and never returned even with forcing garbage collection.
So my hope is that there is some way of "destroying" the definition of the class once it runs to completion. This would also get rid of the WebView definition within the class as well (I hope).
This is my last step in my project. I sincerely hope there is a solution. Any help will be sincerely appreciated.
Thanks,
Craig
Because it has a Webview in it, I cannot declare the class in the Process_Globals section of my service. So I am forced in a regular Sub to do something like:
Dim readReports as GetReports
readReports.Initialize(...)
readReports.PullFromWeb(Main.the_user,Main.the_password)
It works. But I am leaking memory. In a service, I call the class once an hour. Each time (checking the memory used) I can see memory being allocated and never returned even with forcing garbage collection.
So my hope is that there is some way of "destroying" the definition of the class once it runs to completion. This would also get rid of the WebView definition within the class as well (I hope).
This is my last step in my project. I sincerely hope there is a solution. Any help will be sincerely appreciated.
Thanks,
Craig