Click here to Skip to main content
16,010,650 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: WM_TIMER? - (semi real time) - (I'M VERY NOVICE) - (4 short questions) Pin
C-J Berg18-Mar-02 1:58
C-J Berg18-Mar-02 1:58 
GeneralRe: WM_TIMER? - (semi real time) - (I'M VERY NOVICE) - (4 short questions) Pin
Joan M18-Mar-02 5:36
professionalJoan M18-Mar-02 5:36 
GeneralRe: WM_TIMER? - (semi real time) - (I'M VERY NOVICE) - (4 short questions) Pin
C-J Berg18-Mar-02 6:38
C-J Berg18-Mar-02 6:38 
GeneralRe: WM_TIMER? - (semi real time) - (I'M VERY NOVICE) - (4 short questions) Pin
Tomasz Sowinski18-Mar-02 7:17
Tomasz Sowinski18-Mar-02 7:17 
GeneralRe: WM_TIMER? - (semi real time) - (I'M VERY NOVICE) - (4 short questions) Pin
C-J Berg19-Mar-02 1:56
C-J Berg19-Mar-02 1:56 
GeneralRe: WM_TIMER? - (semi real time) - (I'M VERY NOVICE) - (4 short questions) Pin
Tomasz Sowinski19-Mar-02 2:08
Tomasz Sowinski19-Mar-02 2:08 
GeneralRe: WM_TIMER? - (semi real time) - (I'M VERY NOVICE) - (4 short questions) Pin
C-J Berg19-Mar-02 2:37
C-J Berg19-Mar-02 2:37 
GeneralRe: WM_TIMER? - (semi real time) - (I'M VERY NOVICE) - (4 short questions) Pin
Joan M19-Mar-02 23:20
professionalJoan M19-Mar-02 23:20 
Hello,

INTRODUCTION:
First of all let me thank you very much for your help.

I think that using a thread in order to read and another one in order to write (with different priorities) will be a great solution for me.

As I had written down in the Subject of my first message I'm very novice, but I've bought a Jeffrey Richter book that talks widely about threads and I think that, with this book, I will learn how to manage and use correctly threads.

But I have a doubt:

QUESTION:
OK, I will have a thread that will get all the needed data from the XProgram, and I'll have another thread that will write data to that program too (I think that I'll need some kind of "transfer stack" that I'll will have to modify from outside the threads in order to make them work (one for each thread)...) but, now that it seems that I will simplify the fact of getting and setting data to the XProgram, I would like to know how to send that data to the place where it have to go.


Let me explain better:

>> I'll have a transfer stack for reading from the XProgram.

>> This transfer stack will contain all the variables that I have to read from the XProgram.

>> I will use some kind of filters that will avoid reading groups of variables that I don't need by the moment.

>> I will know wich group of variables have suffered a change in the XProgram.

>> I want to send all the variable groups (those in which some var. have changed) to the dialog that use that information.

-----------------------------------------------------------------------------

Which would be the best solution?

ID: 01
DESCRIPTION: Sending messages to the main application window passing the first parameter as a mask of the variables group that has been modified in order to be able to call the right update function (in other dialogs that I'll need acces to (ths is not a problem from the main window)).
COMMENT: Wouldn't be a slow method due to the messages queue?

ID: 02
DESCRIPTION: Calling an updateGUI function in each dialog that need it.
COMMENT: Does is this possible? and moreover I will need access to all those functions in all the dialogs...

ID: 03
DESCRIPTION: having the same timers that allow me to update the GUI?.
COMMENT: why do I use the two threads then?

-----------------------------------------------------------------------------

Of course I have not still readed all about threads that is in that Jeff. Richter book, but could you give me an advice about this?

Thank you again, and let me promise you that I wont annoy you again with questions without reading all about threading in the Richter's book.
GeneralRe: WM_TIMER? - (semi real time) - (I'M VERY NOVICE) - (4 short questions) Pin
JT Anderson18-Mar-02 8:14
JT Anderson18-Mar-02 8:14 
GeneralRegistry Operations Pin
udayakumar18-Mar-02 0:38
udayakumar18-Mar-02 0:38 
GeneralRe: Registry Operations Pin
Tomasz Sowinski18-Mar-02 0:43
Tomasz Sowinski18-Mar-02 0:43 
GeneralRe: Registry Operations Pin
Abhishek Narula18-Mar-02 0:52
Abhishek Narula18-Mar-02 0:52 
GeneralRe: Registry Operations Pin
Abhishek Narula18-Mar-02 1:05
Abhishek Narula18-Mar-02 1:05 
GeneralRe: Registry Operations Pin
udayakumar18-Mar-02 1:38
udayakumar18-Mar-02 1:38 
GeneralDisable audio port Pin
Halid Niyaz18-Mar-02 0:04
Halid Niyaz18-Mar-02 0:04 
GeneralMultiple View Application Pin
Abhishek Narula17-Mar-02 23:40
Abhishek Narula17-Mar-02 23:40 
GeneralRe: Multiple View Application Pin
Tomasz Sowinski18-Mar-02 0:24
Tomasz Sowinski18-Mar-02 0:24 
GeneralRe: Multiple View Application Pin
Abhishek Narula18-Mar-02 0:32
Abhishek Narula18-Mar-02 0:32 
GeneralRe: Multiple View Application Pin
Tomasz Sowinski18-Mar-02 0:40
Tomasz Sowinski18-Mar-02 0:40 
GeneralActive document container & menu icons Pin
C-J Berg17-Mar-02 23:37
C-J Berg17-Mar-02 23:37 
GeneralWriting Text on Window using TextOut Pin
vkumara17-Mar-02 23:08
vkumara17-Mar-02 23:08 
GeneralRe: Writing Text on Window using TextOut Pin
Tomasz Sowinski17-Mar-02 23:23
Tomasz Sowinski17-Mar-02 23:23 
GeneralRe: Writing Text on Window using TextOut Pin
Stan Shannon17-Mar-02 23:33
Stan Shannon17-Mar-02 23:33 
GeneralRe: Writing Text on Window using TextOut Pin
18-Mar-02 0:29
suss18-Mar-02 0:29 
QuestionHow to get the left string of the caret? Pin
Feng Qin17-Mar-02 21:24
Feng Qin17-Mar-02 21:24 

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.