Sujaanpals
Mar 6th, 2002, 12:01 PM
I want to make frame's BackColor gradient.
Like want to make label gradient we can set backstyle=1-opaque.
Please help me
My q is to make frame's BackColor gradient ?
Hack
Mar 6th, 2002, 02:28 PM
Put a PictureBox inside your frame, and size it to the frame size. Try this:Private Sub Grafitti(MyPB As PictureBox)
Dim x As Integer
Dim Colo As Integer
Dim x1 As Integer
Dim x2 As Integer
Dim y1 As Integer
Dim y2 As Integer
MyPB.BackColor = vbBlack
MyPB.ScaleHeight = 100
MyPB.ScaleWidth = 100
For x = 0 To 300
DoEvents
x1 = Int(Rnd * 101)
x2 = Int(Rnd * 101)
y1 = Int(Rnd * 101)
y2 = Int(Rnd * 101)
Colo = Int(Rnd * 15)
MyPB.Line (x1, y1)-(x2, y2), QBColor(Colo)
MyPB.Line (x1, y2)-(x2, y1), QBColor(Colo)
MyPB.Line (x2, y1)-(x1, y2), QBColor(Colo)
MyPB.Line (y1, y2)-(x1, x2), QBColor(Colo)
Next x
End Sub
Private Sub Command1_Click()
Grafitti Picture1
End Sub