Click here to Skip to main content
15,917,642 members
Home / Discussions / C#
   

C#

 
GeneralRe: How to set text of textbox with value user entered in another form at form close Pin
linqabc17-Apr-10 22:26
linqabc17-Apr-10 22:26 
GeneralRe: How to set text of textbox with value user entered in another form at form close Pin
OriginalGriff17-Apr-10 22:36
mveOriginalGriff17-Apr-10 22:36 
GeneralRe: How to set text of textbox with value user entered in another form at form close Pin
linqabc17-Apr-10 22:52
linqabc17-Apr-10 22:52 
GeneralRe: How to set text of textbox with value user entered in another form at form close (alternative method) Pin
supercat919-Apr-10 5:48
supercat919-Apr-10 5:48 
QuestionOutlook Plug-in Button Issue! Pin
Sr...Frank16-Apr-10 23:09
Sr...Frank16-Apr-10 23:09 
AnswerRe: Outlook Plug-in Button Issue! Pin
Md. Marufuzzaman18-Apr-10 1:38
professionalMd. Marufuzzaman18-Apr-10 1:38 
QuestionTimer tick event count Pin
mprice21416-Apr-10 18:00
mprice21416-Apr-10 18:00 
AnswerRe: Timer tick event count Pin
OriginalGriff16-Apr-10 21:48
mveOriginalGriff16-Apr-10 21:48 
Just set up:
private double myTime = 0.0;
as a class field.
In your Load event or constructor:
Timer tim = new Timer();
tim.Interval = 1000;
tim.Tick += new new EventHandler(timer_Tick);
tim.Start();
And add the Tick event handler:
void timer_Tick(object sender, EventArgs e)
   {
   myTime+= 1.0;
   }


However, it may be easier and better to save the start time as a DateTime; and subtract it from DateTime.Now in your update method. You can then get the elapsed seconds from the resulting TimeSpan.
You should never use standby on an elephant. It always crashes when you lift the ears. - Mark Wallace

C/C++ (I dont see a huge difference between them, and the 'benefits' of C++ are questionable, who needs inheritance when you have copy and paste) - fat_boy

GeneralRe: Timer tick event count Pin
mprice21417-Apr-10 4:07
mprice21417-Apr-10 4:07 
GeneralRe: Timer tick event count Pin
OriginalGriff17-Apr-10 4:51
mveOriginalGriff17-Apr-10 4:51 
QuestionDisconnected Context Issue Pin
tims8116-Apr-10 14:03
tims8116-Apr-10 14:03 
AnswerRe: Disconnected Context Issue Pin
cbin9-Feb-11 22:34
cbin9-Feb-11 22:34 
Questionhow to input image in c#[modified] Pin
samuel200216-Apr-10 10:31
samuel200216-Apr-10 10:31 
AnswerRe: how to input image in c Pin
Tarakeshwar Reddy16-Apr-10 11:37
professionalTarakeshwar Reddy16-Apr-10 11:37 
QuestionHow to Make textbox autocomplete? Pin
lamiaa_12316-Apr-10 10:13
lamiaa_12316-Apr-10 10:13 
AnswerRe: How to Make textbox autocomplete? Pin
Jimmanuel16-Apr-10 10:24
Jimmanuel16-Apr-10 10:24 
GeneralRe: How to Make textbox autocomplete? Pin
linqabc16-Apr-10 22:56
linqabc16-Apr-10 22:56 
GeneralRe: How to Make textbox autocomplete? Pin
Jimmanuel17-Apr-10 1:47
Jimmanuel17-Apr-10 1:47 
AnswerRe: How to Make textbox autocomplete? Pin
Ravi Bhavnani16-Apr-10 12:29
professionalRavi Bhavnani16-Apr-10 12:29 
QuestionHow to auto-select a newly added row in the DataGrid? [modified] Pin
Donnelly James16-Apr-10 9:23
Donnelly James16-Apr-10 9:23 
AnswerRe: How to auto-select a newly added row in the DataGrid? Pin
Dave Buhl16-Apr-10 12:04
Dave Buhl16-Apr-10 12:04 
GeneralRe: How to auto-select a newly added row in the DataGrid? Pin
Donnelly James19-Apr-10 3:53
Donnelly James19-Apr-10 3:53 
GeneralRe: How to auto-select a newly added row in the DataGrid? Pin
Dave Buhl19-Apr-10 6:13
Dave Buhl19-Apr-10 6:13 
GeneralRe: How to auto-select a newly added row in the DataGrid? Pin
Donnelly James21-Apr-10 4:16
Donnelly James21-Apr-10 4:16 
AnswerRe: How to auto-select a newly added row in the DataGrid? Pin
Donnelly James23-Apr-10 5:10
Donnelly James23-Apr-10 5:10 

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.