Click here to Skip to main content
15,885,278 members
Home / Discussions / C#
   

C#

 
AnswerRe: Inet in C# ? Pin
eggie52-Oct-04 16:25
eggie52-Oct-04 16:25 
GeneralRe: Inet in C# ? Pin
youssef3-Oct-04 0:01
youssef3-Oct-04 0:01 
AnswerRe: Inet in C# ? Pin
Nnamdi Onyeyiri3-Oct-04 0:00
Nnamdi Onyeyiri3-Oct-04 0:00 
GeneralRe: Inet in C# ? Pin
youssef3-Oct-04 0:46
youssef3-Oct-04 0:46 
AnswerRe: Inet in C# ? Pin
Salil Khedkar4-Oct-04 20:57
Salil Khedkar4-Oct-04 20:57 
AnswerRe: Inet in C# ? Pin
youssef5-Oct-04 12:50
youssef5-Oct-04 12:50 
QuestionA timer func problem??? Pin
cemlouis2-Oct-04 14:08
cemlouis2-Oct-04 14:08 
AnswerRe: A timer func problem??? Pin
partyganger2-Oct-04 16:21
partyganger2-Oct-04 16:21 
Add a boolean class member that starts out as false. Whenever the timer event is triggered, check if it's false. If so, set it to true. In the ListBox SelectedIndexChanged event handler (or whatever the event is called that gets called whenever you select a different item from the listbox), set the boolean to false again, thus resetting it and allowing the timer event to run again.
This way, Process() can only run when a different item has been selected. And since the Process() then sets the boolean flag to true, it will only run once.
<br />
bool itemIsInTimer = false;<br />
<br />
private void listbox1_SelectedIndexChanged(object sender, System.EventArgs e)<br />
{<br />
 this.itemIsInTimer = false;<br />
}<br />
<br />
private void process()<br />
{<br />
if(!this.itemIsInTimer)<br />
{<br />
this.itemIsInTimer = true;<br />
// do process<br />
}<br />
}<br />

Questionadding to the byte[] ? Pin
SniperED0072-Oct-04 10:00
SniperED0072-Oct-04 10:00 
AnswerRe: adding to the byte[] ? Pin
Nnamdi Onyeyiri2-Oct-04 23:58
Nnamdi Onyeyiri2-Oct-04 23:58 
GeneralColor of Column Headers in a DataGrid Pin
MarkMokris2-Oct-04 7:44
MarkMokris2-Oct-04 7:44 
GeneralRe: Color of Column Headers in a DataGrid Pin
sreejith ss nair3-Oct-04 19:50
sreejith ss nair3-Oct-04 19:50 
GeneralBest way to store and access Global variables Pin
Zapss2-Oct-04 3:02
Zapss2-Oct-04 3:02 
GeneralRe: Best way to store and access Global variables Pin
Colin Angus Mackay2-Oct-04 4:00
Colin Angus Mackay2-Oct-04 4:00 
GeneralRe: Best way to store and access Global variables Pin
Andres Coder3-Oct-04 6:14
Andres Coder3-Oct-04 6:14 
GeneralDesign Optimization Pin
sreejith ss nair2-Oct-04 2:56
sreejith ss nair2-Oct-04 2:56 
GeneralRe: Design Optimization Pin
Colin Angus Mackay2-Oct-04 4:11
Colin Angus Mackay2-Oct-04 4:11 
GeneralRe: Design Optimization Pin
sreejith ss nair2-Oct-04 18:43
sreejith ss nair2-Oct-04 18:43 
GeneralRe: Design Optimization Pin
Nnamdi Onyeyiri2-Oct-04 12:14
Nnamdi Onyeyiri2-Oct-04 12:14 
GeneralRe: Design Optimization Pin
sreejith ss nair2-Oct-04 18:43
sreejith ss nair2-Oct-04 18:43 
GeneralRe: Design Optimization Pin
hatim_ali3-Oct-04 19:33
hatim_ali3-Oct-04 19:33 
GeneralRe: Design Optimization Pin
sreejith ss nair3-Oct-04 19:48
sreejith ss nair3-Oct-04 19:48 
GeneralRe: Design Optimization Pin
Dave Kreskowiak4-Oct-04 7:07
mveDave Kreskowiak4-Oct-04 7:07 
Generalimage.saveadd function Pin
hudhud2-Oct-04 2:52
hudhud2-Oct-04 2:52 
GeneralRename XmlNode in Dom Pin
Anonymous2-Oct-04 1:52
Anonymous2-Oct-04 1:52 

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.