Click here to Skip to main content
15,886,519 members
Home / Discussions / C#
   

C#

 
GeneralRe: File Manipulation Pin
LCI19-Nov-07 16:43
LCI19-Nov-07 16:43 
Questionlogin page problem Pin
rocky81119-Nov-07 6:22
rocky81119-Nov-07 6:22 
AnswerRe: login page problem Pin
Anthony Mushrow19-Nov-07 6:33
professionalAnthony Mushrow19-Nov-07 6:33 
GeneralRe: login page problem Pin
rocky81119-Nov-07 6:34
rocky81119-Nov-07 6:34 
QuestionGeneral Questions using Attach Process [modified] Pin
Khoramdin19-Nov-07 6:18
Khoramdin19-Nov-07 6:18 
QuestionSome issue with thread synchronization & events Pin
Karma Komae19-Nov-07 5:44
Karma Komae19-Nov-07 5:44 
AnswerRe: Some issue with thread synchronization & events Pin
Judah Gabriel Himango19-Nov-07 9:31
sponsorJudah Gabriel Himango19-Nov-07 9:31 
GeneralRe: Some issue with thread synchronization & events Pin
Karma Komae19-Nov-07 21:56
Karma Komae19-Nov-07 21:56 
Hello, and thank you for your reply !

Well, this is what i thought, but i don't know how to do that another way Frown | :-(

I'm writing an interactive application, with a RichTextBox containing a script to process and get the answer to these lines. It has to handle debug features such as run, step by step, breakpoints, halt, and so on.

The thing is, i've got a main thread (my windows form), and i have to do two things :

1/ Have a background thread to listen to data input, that may come at anytime (i.e. even when the script is not processing, but have the possibility to disable it in order to process some specific commands)

2/ Have another thread to process the script lines, one by one or the whole script depending on the debug button pressed.

To me, i don't see another way to do that. Considering the reading thread for example, it has to loop for data input, unless i tell it to stop/pause. So i thought it was the right way to implement this feature.

Now after reading from you, i guess it's not right to start/stop constantly the threads, because for the step by step for example, i run the process thread just for one line and then i cut it off before the user asks for another interaction. I've also thought at using the events to pause the threads but it wasn't doing what i expected (maybe i've done some mistake on that implementation, i tried it in a hurry). But the thing is that i need to know when a thread is running, then have the ability to tell it to stop/pause and be sure it has done processing before performing the remaining operations.

As i have two loops (one for each thread), i can't find out another way that polling at each loop if they're asked to stop/pause.

I hope it's more clear for you now, and i also hope you can give me hand to find out how to implement that correctly !


Best Regards,

Mamat,

QuestionDataBound DataGridView Relational DB Problem Pin
shirazamod19-Nov-07 5:03
shirazamod19-Nov-07 5:03 
AnswerRe: DataBound DataGridView Relational DB Problem Pin
pmarfleet19-Nov-07 9:04
pmarfleet19-Nov-07 9:04 
GeneralRe: DataBound DataGridView Relational DB Problem Pin
shirazamod19-Nov-07 9:45
shirazamod19-Nov-07 9:45 
GeneralRe: DataBound DataGridView Relational DB Problem Pin
pmarfleet19-Nov-07 9:50
pmarfleet19-Nov-07 9:50 
QuestionEnumerators and locks. Pin
jmhamm19-Nov-07 4:40
jmhamm19-Nov-07 4:40 
AnswerRe: Enumerators and locks. Pin
Bekjong19-Nov-07 5:00
Bekjong19-Nov-07 5:00 
GeneralRe: Enumerators and locks. Pin
jmhamm19-Nov-07 5:08
jmhamm19-Nov-07 5:08 
AnswerRe: Enumerators and locks. Pin
Daniel Grunwald19-Nov-07 11:42
Daniel Grunwald19-Nov-07 11:42 
QuestionFindControl on Fields on an aspx screen. Pin
imnotso#19-Nov-07 4:33
imnotso#19-Nov-07 4:33 
AnswerRe: FindControl on Fields on an aspx screen. Pin
Anthony Mushrow19-Nov-07 4:42
professionalAnthony Mushrow19-Nov-07 4:42 
GeneralRe: FindControl on Fields on an aspx screen. Pin
imnotso#19-Nov-07 4:58
imnotso#19-Nov-07 4:58 
AnswerRe: FindControl on Fields on an aspx screen. Pin
martin_hughes19-Nov-07 5:27
martin_hughes19-Nov-07 5:27 
GeneralRe: FindControl on Fields on an aspx screen. Pin
imnotso#19-Nov-07 5:36
imnotso#19-Nov-07 5:36 
GeneralRe: FindControl on Fields on an aspx screen. Pin
Anthony Mushrow19-Nov-07 5:42
professionalAnthony Mushrow19-Nov-07 5:42 
GeneralRe: FindControl on Fields on an aspx screen. Pin
imnotso#19-Nov-07 5:55
imnotso#19-Nov-07 5:55 
GeneralRe: FindControl on Fields on an aspx screen. Pin
Anthony Mushrow19-Nov-07 6:08
professionalAnthony Mushrow19-Nov-07 6:08 
GeneralRe: FindControl on Fields on an aspx screen. Pin
imnotso#19-Nov-07 6:13
imnotso#19-Nov-07 6:13 

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.