Click here to Skip to main content
15,918,624 members
Home / Discussions / C#
   

C#

 
AnswerRe: Events in Interfaces Pin
Not Active5-Dec-10 16:30
mentorNot Active5-Dec-10 16:30 
GeneralRe: Events in Interfaces Pin
Richard Andrew x645-Dec-10 16:34
professionalRichard Andrew x645-Dec-10 16:34 
Questionevents between two threads Pin
igalep1325-Dec-10 8:03
igalep1325-Dec-10 8:03 
AnswerRe: events between two threads Pin
Luc Pattyn5-Dec-10 8:45
sitebuilderLuc Pattyn5-Dec-10 8:45 
GeneralRe: events between two threads Pin
igalep1325-Dec-10 8:55
igalep1325-Dec-10 8:55 
GeneralRe: events between two threads Pin
Luc Pattyn5-Dec-10 9:42
sitebuilderLuc Pattyn5-Dec-10 9:42 
GeneralRe: events between two threads Pin
igalep1325-Dec-10 9:48
igalep1325-Dec-10 9:48 
GeneralRe: events between two threads Pin
Luc Pattyn5-Dec-10 9:57
sitebuilderLuc Pattyn5-Dec-10 9:57 
maybe you should look into the yield keyword, it offers a way to return results from a method while allowing said method to continue execution later on. Not sure how well it fits recursive methods, I read it would work fine but my very first experiment (long ago) failed.

FWIW: if all you need is some kind of continue/cancel input, you can organize that by having the main thread taking care of the user interface (buttons, checkboxes, ...) and setting some variable(s) to reflect what the user did, and your background calculation simply reading those variables whenever it feels like it.

Smile | :)
Luc Pattyn [Forum Guidelines] [Why QA sucks] [My Articles] Nil Volentibus Arduum
Please use <PRE> tags for code snippets, they preserve indentation, improve readability, and make me actually look at the code.


AnswerRe: events between two threads Pin
Not Active5-Dec-10 9:28
mentorNot Active5-Dec-10 9:28 
GeneralRe: events between two threads Pin
igalep1325-Dec-10 9:38
igalep1325-Dec-10 9:38 
GeneralRe: events between two threads Pin
Not Active5-Dec-10 9:56
mentorNot Active5-Dec-10 9:56 
GeneralRe: events between two threads [modified] Pin
igalep1325-Dec-10 10:47
igalep1325-Dec-10 10:47 
AnswerRe: yield Pin
Luc Pattyn5-Dec-10 11:25
sitebuilderLuc Pattyn5-Dec-10 11:25 
GeneralRe: yield Pin
Not Active5-Dec-10 11:32
mentorNot Active5-Dec-10 11:32 
GeneralRe: yield Pin
Pete O'Hanlon5-Dec-10 11:33
mvePete O'Hanlon5-Dec-10 11:33 
GeneralRe: yield Pin
Luc Pattyn5-Dec-10 11:37
sitebuilderLuc Pattyn5-Dec-10 11:37 
GeneralRe: yield Pin
igalep13211-Dec-10 0:45
igalep13211-Dec-10 0:45 
GeneralRe: yield Pin
Luc Pattyn11-Dec-10 1:00
sitebuilderLuc Pattyn11-Dec-10 1:00 
GeneralRe: yield [modified] Pin
igalep13211-Dec-10 4:53
igalep13211-Dec-10 4:53 
AnswerRe: yield Pin
Luc Pattyn11-Dec-10 14:03
sitebuilderLuc Pattyn11-Dec-10 14:03 
GeneralRe: events between two threads Pin
Not Active5-Dec-10 11:38
mentorNot Active5-Dec-10 11:38 
GeneralRe: events between two threads [modified] Pin
igalep1326-Dec-10 10:40
igalep1326-Dec-10 10:40 
GeneralRe: events between two threads Pin
Not Active6-Dec-10 10:58
mentorNot Active6-Dec-10 10:58 
GeneralRe: events between two threads Pin
igalep1326-Dec-10 11:14
igalep1326-Dec-10 11:14 
AnswerRe: events between two threads Pin
Luc Pattyn5-Dec-10 12:27
sitebuilderLuc Pattyn5-Dec-10 12:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.