Shadow for controls
i saw many people creating shadow by adding a label control it dosent matter if you have min no of controls but when you have large no of controls
So here is the code to create shadow without using any other controls
Just paste this code ***Have Fun***
Original Author: Joseph Varghese
Assumptions
Create shadow just using code
Code
Public Sub SHADOW(Frm As Form, Ctrl As Control)
Const SC = vbBlack 'you can define your own color
Const SW = 3
Dim IOLDWIDTH As Integer
Dim IOLDSCALE As Integer
IOLDWIDTH = Frm.DrawWidth
IOLDSCALE = Frm.ScaleMode
Frm.ScaleMode = 3
Frm.DrawWidth = 1
Frm.Line (Ctrl.Left + SW, Ctrl.Top + SW)-Step(Ctrl.Width - 1, Ctrl.Height - 1), SC, BF
Frm.DrawWidth = IOLDWIDTH
Frm.ScaleMode = IOLDSCALE
End Sub
Private Sub Form_paint()
SHADOW Me, Command1
End Sub
Loading Comments ...
Comments
No comments have been added for this post.
You must be logged in to make a comment.