Imam jedan problem sa tajmerom.
napisao sam ovaj kod za tajmer:
Private Brojacstatuslabel As Integer = 0 ' Deklarisao sam Brojacstatuslabel
Dim nazivservisa As New System.IO.StreamReader("C:\Program Files\EVUS\EVUS\Baze\Imeservisa.EVUS") 'Fajl sto se cita
ToolStripStatusLabel.Text = "EVUS " + """" + nazivservisa.ReadToEnd + """"
Brojacstatuslabel = (Brojacstatuslabel + 1)
If (Brojacstatuslabel = 15) Then
ToolStripStatusLabel.Text = "EVUS " + """" + nazivservisa.ReadToEnd + """"
End If
a ovo sam stavio u svako dugme, ima sada tu vise dugmica ali evo kod iz jednog:
Brojacstatuslabel = 0
ToolStripStatusLabel.Text = "Pregled vozila"
Form1.MdiParent = Me
Form1.Show()
E ovaj kod je nekada radio i sada nece. Kada kliknem dugme pise "Pregled vozila na pola sekunde i pojavi se Dim nazivservisa As New System.IO.StreamReader("C:\Program Files\EVUS\EVUS\Baze\Imeservisa.EVUS")
Interval sam postavio na 350 a enabled na true
Ranije dok je taj kod radio bilo je oko 10 sec "Pregled vozila" pa se pojavi onaj fajl a sad nece da radi. hajde mi recite u cemu je problem, ako znate!
Dopuna: 14 Jan 2009 19:00
R E S E N O ! ! !
Dim nazivservisa As New System.IO.StreamReader("C:\Program Files\EVUS\EVUS\Baze\Imeservisa.EVUS") 'Fajl sto se cita
ToolStripStatusLabel.Text = "EVUS " + """" + nazivservisa.ReadToEnd + """"
Brojacstatuslabel = (Brojacstatuslabel + 1)
If (Brojacstatuslabel = 15) Then
ToolStripStatusLabel.Text = "EVUS " + """" + nazivservisa.ReadToEnd + """"
End If
A ispravno je ovako:
Dim nazivservisa As New System.IO.StreamReader("C:\Program Files\EVUS\EVUS\Baze\Imeservisa.EVUS") 'Fajl sto se cita
Brojacstatuslabel = (Brojacstatuslabel + 1)
If (Brojacstatuslabel = 15) Then
ToolStripStatusLabel.Text = "EVUS " + """" + nazivservisa.ReadToEnd + """"
End If
Mora da sam greskom dodao taj red. Kome jos ta linija koda treba...
|