Jump to content
Forum Windows-az.com

VB-də Randomize (Rəng dəyişməsi)


Ʌüsal

Recommended Posts

Forma 1 ədəd TextBox 1 ədəd ComboBox 2 ədəd RadioButton 1 ədəd Timer yerləşdirin.

 

Daha sonra işə aşağıdakı kodu Forma sırası ilə daxil edin.

 

Public Class Form1

 

    Private Sub RadioButton1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RadioButton1.CheckedChanged

        Timer1.Start()

        Timer1.Interval = 1000

    End Sub

 

    Private Sub RadioButton2_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RadioButton2.CheckedChanged

        Timer1.Start()

        Timer1.Interval = 1000

    End Sub

 

    Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick

        Dim a, b, c As String

        If RadioButton1.Checked Then

            Randomiz

e()

            a = Rnd() * 255

            b = Rnd() * 255

            c = Rnd() * 255

            Me.BackC

olor = Color.FromArgb(a, b, c)

 

        End If

        Dim d, f, g As String

        If RadioButton2.Checked Then

        End If

        Randomize()

        d = Rnd() * 255

        f = Rnd() * 255

        g = Rnd() * 255

        TextBox1.BackColor = Color.FromArgb(d, f, g)

    End Sub

 

    Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedIndexChanged

        If ComboBox1.Text = "Başla" Then

            Timer1.S

tart()

        End If

        If ComboBox1.Text = "Dayandır" Then

        End If

        Timer1.Stop()

    End Sub

End Class

 

 

1308166122_1.gif

- Laptop ve Desktop Anakartlarin temiri

- BIOS yazilmasi

- Sifreli SuperUser BIOS-larin silinmesi

- Kicik chiplerin deyisidrilmesi

- BGA Chiplerin deyisdirilmesi (GPU/CPU/FCH/PCH/HM ve s)

Link to comment
Share on other sites

Proqramlar telegramda

Sohbete katıl

Şimdi mesajını gönderebilir ve daha sonra kayıt olabilirsin. Bir hesabın varsa, hesabınla göndermek için şimdi oturum aç.

Misafir
Bu konuya yanıt ver...

×   Zengin metin olarak yapıştırıldı.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Önceki içeriğiniz geri yüklendi.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • loading...
×
×
  • Create New...