Click here to Skip to main content
15,569,768 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionEmail Host Pin
The ANZAC19-Feb-07 19:47
The ANZAC19-Feb-07 19:47 
AnswerRe: Email Host Pin
Christian Graus19-Feb-07 20:07
mveChristian Graus19-Feb-07 20:07 
GeneralRe: Email Host Pin
The ANZAC19-Feb-07 20:30
The ANZAC19-Feb-07 20:30 
GeneralRe: Email Host Pin
The ANZAC19-Feb-07 21:03
The ANZAC19-Feb-07 21:03 
QuestionDatagrid in vb.net Pin
Pertik Garg19-Feb-07 19:16
Pertik Garg19-Feb-07 19:16 
AnswerRe: Datagrid in vb.net Pin
GoodID19-Feb-07 22:10
GoodID19-Feb-07 22:10 
AnswerRe: Datagrid in vb.net Pin
NanaAM20-Feb-07 1:54
NanaAM20-Feb-07 1:54 
QuestionReset an integer Pin
rudemusik19-Feb-07 16:38
rudemusik19-Feb-07 16:38 
Hello all!

I can't beleive I can't get this, but here it goes. I want to reset a integer number that used for a time. So at the top I have

Public mysec As Integer = 15
Then I have this for my timer
Private Sub tmrGame_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles tmrGame.Tick<br />
        Threading.Thread.SpinWait(1000)<br />
        mysec = mysec - 1<br />
        lblcdClock.Text = ":" & mysec<br />
        If mysec > 15 Then<br />
            mysec = 0<br />
        End If<br />
        If mysec = -1 Then<br />
            tmrGame.Stop()<br />
            lblcdClock.Text = ":" & 0<br />
            Threading.Thread.Sleep(2000)<br />
            lblcdClock.Text = ":" & 15<br />
               End If<br />
    End Sub


How can I reset "mysec" to 15 so when the time stops, and I start it agin, it start from 15? Using VS 2003.

Thanks!

Rudy
AnswerRe: Reset an integer Pin
Christian Graus19-Feb-07 20:10
mveChristian Graus19-Feb-07 20:10 
GeneralRe: Reset an integer Pin
rudemusik20-Feb-07 14:20
rudemusik20-Feb-07 14:20 
GeneralRe: Reset an integer Pin
TwoFaced20-Feb-07 19:32
TwoFaced20-Feb-07 19:32 
GeneralRe: Reset an integer Pin
rudemusik21-Feb-07 6:31
rudemusik21-Feb-07 6:31 
AnswerRe: Reset an integer Pin
lucky.prem19-Feb-07 21:03
lucky.prem19-Feb-07 21:03 
GeneralRe: Reset an integer Pin
rudemusik20-Feb-07 14:28
rudemusik20-Feb-07 14:28 
QuestionRead last line of logfile and close file immediately Pin
bodobe19-Feb-07 11:10
bodobe19-Feb-07 11:10 
AnswerRe: Read last line of logfile and close file immediately Pin
Marcus J. Smith19-Feb-07 11:14
professionalMarcus J. Smith19-Feb-07 11:14 
GeneralRe: Read last line of logfile and close file immediately Pin
bodobe19-Feb-07 11:23
bodobe19-Feb-07 11:23 
GeneralRe: Read last line of logfile and close file immediately Pin
Marcus J. Smith19-Feb-07 11:29
professionalMarcus J. Smith19-Feb-07 11:29 
GeneralRe: Read last line of logfile and close file immediately Pin
bodobe19-Feb-07 11:40
bodobe19-Feb-07 11:40 
GeneralRe: Read last line of logfile and close file immediately Pin
Marcus J. Smith19-Feb-07 11:47
professionalMarcus J. Smith19-Feb-07 11:47 
AnswerRe: Read last line of logfile and close file immediately Pin
TwoFaced19-Feb-07 14:06
TwoFaced19-Feb-07 14:06 
GeneralRe: Read last line of logfile and close file immediately Pin
bodobe20-Feb-07 21:43
bodobe20-Feb-07 21:43 
GeneralRe: Read last line of logfile and close file immediately Pin
TwoFaced20-Feb-07 22:32
TwoFaced20-Feb-07 22:32 
GeneralRe: Read last line of logfile and close file immediately Pin
Marcus J. Smith23-Feb-07 6:20
professionalMarcus J. Smith23-Feb-07 6:20 
QuestionVB6.0 - Common Dialog "ShowSave" method to get a Folder? Pin
ChemmieBro19-Feb-07 10:55
ChemmieBro19-Feb-07 10:55 

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.