Click here to Skip to main content
15,888,984 members
Home / Discussions / C#
   

C#

 
GeneralRe: How to monitor and block a registry key change? Pin
Dave Kreskowiak31-Jul-13 5:58
mveDave Kreskowiak31-Jul-13 5:58 
GeneralRe: How to monitor and block a registry key change? Pin
Eddy Vluggen31-Jul-13 8:39
professionalEddy Vluggen31-Jul-13 8:39 
AnswerRe: How to monitor and block a registry key change? Pin
FIorian Schneidereit30-Jul-13 15:54
FIorian Schneidereit30-Jul-13 15:54 
GeneralRe: How to monitor and block a registry key change? Pin
turbosupramk331-Jul-13 2:41
turbosupramk331-Jul-13 2:41 
QuestionProblem in creating Report Pin
Arun kumar Gautam30-Jul-13 3:32
Arun kumar Gautam30-Jul-13 3:32 
AnswerRe: Problem in creating Report Pin
Mycroft Holmes30-Jul-13 12:42
professionalMycroft Holmes30-Jul-13 12:42 
JokeRe: Problem in creating Report Pin
UL UL ALBAB30-Jul-13 23:32
UL UL ALBAB30-Jul-13 23:32 
QuestionSystem,Timers.Timer to slow in C# Pin
Member 994007329-Jul-13 23:28
Member 994007329-Jul-13 23:28 
The System.Timers.Timer is too slow in my application. Can you guys please give me a hint?

I wrote this short Code to test the timer.

At first I create a timer:

C#
private void button2_Click(object sender, EventArgs e)
{
   // Create ttimer
    System.Timers.Timer Timer;
    Timer = new System.Timers.Timer();
    Timer.Interval = 20; // Timer Intervall = 20 ms
    Timer.Enabled = true;

    Timer.Elapsed += new ElapsedEventHandler(OnTimedEvent);
}


Afterwards I simple dispolay the elapsed time in a label, so that I can compare theese result with a stop watch:

C#
private void OnTimedEvent(object source, ElapsedEventArgs e)
{
    // Invoke, since it`s anoter thread (?)
    Invoke(new MethodInvoker(delegate
    {
        // add 20 to the value in the textbox
        label1.Text = (Convert.ToInt32(label3.Text) + 20).ToString();
    }));
}

AnswerRe: System,Timers.Timer to slow in C# Pin
Pete O'Hanlon30-Jul-13 0:23
mvePete O'Hanlon30-Jul-13 0:23 
GeneralRe: System,Timers.Timer to slow in C# Pin
Member 994007330-Jul-13 1:49
Member 994007330-Jul-13 1:49 
GeneralRe: System,Timers.Timer to slow in C# Pin
AmitGajjar30-Jul-13 2:41
professionalAmitGajjar30-Jul-13 2:41 
GeneralRe: System,Timers.Timer to slow in C# Pin
Member 994007330-Jul-13 2:56
Member 994007330-Jul-13 2:56 
GeneralRe: System,Timers.Timer to slow in C# Pin
AmitGajjar30-Jul-13 19:29
professionalAmitGajjar30-Jul-13 19:29 
AnswerRe: System,Timers.Timer to slow in C# Pin
Eddy Vluggen30-Jul-13 0:26
professionalEddy Vluggen30-Jul-13 0:26 
AnswerRe: System,Timers.Timer to slow in C# Pin
Alan N30-Jul-13 1:26
Alan N30-Jul-13 1:26 
GeneralRe: System,Timers.Timer to slow in C# Pin
Rob Philpott30-Jul-13 19:31
Rob Philpott30-Jul-13 19:31 
AnswerRe: System,Timers.Timer to slow in C# Pin
BillWoodruff30-Jul-13 5:06
professionalBillWoodruff30-Jul-13 5:06 
AnswerRe: System,Timers.Timer to slow in C# Pin
DaveyM6930-Jul-13 6:46
professionalDaveyM6930-Jul-13 6:46 
AnswerRe: System,Timers.Timer to slow in C# Pin
jschell30-Jul-13 8:24
jschell30-Jul-13 8:24 
Questionvb6 dll use in vb.net project but grid not show Pin
sanket16429-Jul-13 22:05
sanket16429-Jul-13 22:05 
SuggestionRe: vb6 dll use in vb.net project but grid not show Pin
Richard MacCutchan29-Jul-13 22:07
mveRichard MacCutchan29-Jul-13 22:07 
QuestionHow to take continuous backup of database Pin
Code-Hunt29-Jul-13 21:03
Code-Hunt29-Jul-13 21:03 
AnswerRe: How to take continuous backup of database Pin
Mycroft Holmes29-Jul-13 21:40
professionalMycroft Holmes29-Jul-13 21:40 
AnswerRe: How to take continuous backup of database Pin
Keith Barrow29-Jul-13 23:26
professionalKeith Barrow29-Jul-13 23:26 
GeneralRe: How to take continuous backup of database Pin
Code-Hunt29-Jul-13 23:28
Code-Hunt29-Jul-13 23:28 

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.