Click here to Skip to main content
15,908,841 members
Home / Discussions / C#
   

C#

 
AnswerRe: oleDB, Odbc, DataBase Pin
Abhijit Jana18-Oct-07 3:48
professionalAbhijit Jana18-Oct-07 3:48 
GeneralRe: oleDB, Odbc, DataBase Pin
half-life18-Oct-07 3:55
half-life18-Oct-07 3:55 
GeneralRe: oleDB, Odbc, DataBase Pin
Abhijit Jana18-Oct-07 4:09
professionalAbhijit Jana18-Oct-07 4:09 
AnswerRe: oleDB, Odbc, DataBase Pin
J4amieC18-Oct-07 3:54
J4amieC18-Oct-07 3:54 
JokeRe: oleDB, Odbc, DataBase Pin
Abhijit Jana18-Oct-07 4:10
professionalAbhijit Jana18-Oct-07 4:10 
QuestionThreading Problem- a thread that calls two functions Pin
gizmokaka18-Oct-07 3:33
gizmokaka18-Oct-07 3:33 
AnswerRe: Threading Problem- a thread that calls two functions Pin
Luc Pattyn18-Oct-07 4:15
sitebuilderLuc Pattyn18-Oct-07 4:15 
GeneralRe: Threading Problem- a thread that calls two functions Pin
gizmokaka18-Oct-07 5:11
gizmokaka18-Oct-07 5:11 
Hi Luc,

The second method (checkProblematicValves) does contain an InvokeRequired/Invoke construct<br />
which is intended to make it execute again on the thread that created valveCheckedListBox,<br />
so yes this method may execute twice.


I don't understand how exactly, Invoke() works, you got me confused.
Can you please explain to me how exactly it works, what do you mean by:
<br />
causing the ENTIRE method to run again


Is the following code what you meant???

private void checkProblematicValves()
        {
            if (valveCheckedListBox.InvokeRequired)
                                {
                                    checkProblematicValvesHendler d = new checkProblematicValvesHendler(checkProblematicValves);
                                    valveCheckedListBox.Invoke(d);
                                }
            else
            {
                foreach (long key in messageArr.Keys)
                {
                    if (messageArr[key] != null)
                    {
                        foreach (object message in messageArr[key])
                        {
                            if (message is Clusters.CSensorStatus)
                            {
                                if ((message as Clusters.CSensorStatus).valveAngDeg > 0 )
                                {
                                    string myKey = LongToHex(key);
                                    int index = valveCheckedListBox.Items.IndexOf(myKey);
                                    valveCheckedListBox.SetItemChecked(index, true);
                                }
                            }
                        }
                    }
                }
            }
        }

GeneralRe: Threading Problem- a thread that calls two functions Pin
Luc Pattyn18-Oct-07 5:27
sitebuilderLuc Pattyn18-Oct-07 5:27 
GeneralRe: Threading Problem- a thread that calls two functions Pin
gizmokaka18-Oct-07 5:48
gizmokaka18-Oct-07 5:48 
GeneralRe: Threading Problem- a thread that calls two functions Pin
Luc Pattyn18-Oct-07 6:58
sitebuilderLuc Pattyn18-Oct-07 6:58 
QuestionAny idea about how to work with IM? Pin
baburman18-Oct-07 3:33
baburman18-Oct-07 3:33 
AnswerRe: Any idea about how to work with IM? Pin
Abhijit Jana18-Oct-07 3:51
professionalAbhijit Jana18-Oct-07 3:51 
GeneralRe: Any idea about how to work with IM? Pin
baburman18-Oct-07 6:36
baburman18-Oct-07 6:36 
AnswerRe: Any idea about how to work with IM? Pin
User 665818-Oct-07 3:56
User 665818-Oct-07 3:56 
GeneralRe: Any idea about how to work with IM? Pin
Abhijit Jana18-Oct-07 4:51
professionalAbhijit Jana18-Oct-07 4:51 
Questiongloabal variable Pin
kabutar18-Oct-07 3:18
kabutar18-Oct-07 3:18 
AnswerRe: gloabal variable Pin
Abhijit Jana18-Oct-07 3:43
professionalAbhijit Jana18-Oct-07 3:43 
GeneralRe: gloabal variable Pin
kabutar18-Oct-07 3:51
kabutar18-Oct-07 3:51 
GeneralRe: gloabal variable Pin
rajansethi18-Oct-07 4:52
rajansethi18-Oct-07 4:52 
AnswerRe: gloabal variable Pin
Luc Pattyn18-Oct-07 4:02
sitebuilderLuc Pattyn18-Oct-07 4:02 
GeneralCustomization of FxCop Pin
bhaskarsri18-Oct-07 2:26
bhaskarsri18-Oct-07 2:26 
GeneralRe: Customization of FxCop Pin
Scott Dorman18-Oct-07 4:08
professionalScott Dorman18-Oct-07 4:08 
GeneralRe: Customization of FxCop Pin
bhaskarsri18-Oct-07 17:35
bhaskarsri18-Oct-07 17:35 
GeneralRe: Customization of FxCop Pin
Scott Dorman19-Oct-07 6:32
professionalScott Dorman19-Oct-07 6:32 

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.