Cross - Threading in .Net 2005
I have a third party control / class that I use in my project. They apparently are running their code on a separate thread. They trigger an event when their process is complete - lets call it "process done". I need to change button and text properties on the UI when the process done event triggers. I cannot find a way to do so in 2005. I get a cross-threading error. See the below example
' This is the declaration for the classprivate withevents myclass as new thirdpartyclass()' Event raised by the class
private sub processdone() handles thirdpartyclass.done
Button1.text = "New Text"'Error occurs here!
end sub
[744 byte] By [
Steve_J] at [2007-12-16]