Search Results

Search found 1 results on 1 pages for 'haughtonomous'.

Page 1/1 | 1 

  • Unexpected cross threading issue

    - by haughtonomous
    I'm trying to do something very simple in principal, but I keep getting a cross-threading exception which has me stumped because I'm not setting out to use multiple threads. I have a Windows Forms application. It launches another Windows Forms application (using the System.Diagnostics.Process class) , and catches the Exited event when that application is closed. My application event handler then tries to copy text from the clipboard to a control on the current displayed form. At this point a Cross-threading exception is thrown. I assume that the problem is that the event from the closing application is in another thread (I'm outside my comfort zone here, so bear with me), so the question boils down to "How do I prevent this exception?" I'm somewhat constrained into having to copy from the clipboard, but I could launch the other application a different way if that would solve the problem.

    Read the article

1