Jump to content

Recommended Posts

Posted (edited)

Boas amigos,

Tenho um projecto que tem 1 botão (Start) e 1 botão (Stop)

Eu pretendia que quando clica-se no botão start o programa fica-se a fazer uns Bip ate eu clicar no botão stop sabem como poderei fazer isso?

Edited by Tatia
Posted (edited)

Tens aqui um exemplo...

Muito obrigado tudo o que precisava mesmo era.

My.Computer.Audio.PlaySystemSound(Media.SystemSounds.Beep)

Obrigado mesmo...

Edite: Problema

Isto foi implementado em um programa de flood.

Antes da implementação a utilização de rede era 97 a 98 % e mantinha essa media...

Agora tenho 80 a 92% o que torna a ligação com uma grande quebra tem como fazer isso em um outro processo ou algo assim?

Actualmente o meu timer esta assim:

Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
    My.Computer.Audio.PlaySystemSound(Media.SystemSounds.Beep)
    If TimeOff.Text <> "" And TimeOff.Text <> "0" Then
	    If Now <= Time Then

		    UdpFlood(TextBox5.Text, TextBox2.Text)

	    Else
		    Label3.Text = VALOR / NumericUpDown1.Text
		    Button1.Visible = True
		    Button2.Visible = False
		    Timer1.Stop()

		    Exit Sub

	    End If

    Else
	    Label3.Text = VALOR / NumericUpDown1.Text
	    UdpFlood(TextBox5.Text, TextBox2.Text)
    End If

   End Sub
Edited by Tatia

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.