ایجاد یک فرم دایره ای در vb
| Private Declare Function CreateEllipticRgn Lib "gdi32" (ByVal X1 As Long, ByVal Y1 As Long, ByVal X2 As Long, ByVal Y2 As Long) As Long Private Declare Function SetWindowRgn Lib "user32" (ByVal hWnd As Long, ByVal hRgn As Long, ByVal bRedraw As Long) As Long |
| 'place this code in the form load event Private Sub Form_Load() Dim lngRegion As Long Dim lngReturn As Long Dim lngFormWidth As Long Dim lngFormHeight As Long lngFormWidth = Me.Width / Screen.TwipsPerPixelX lngFormHeight = Me.Height / Screen.TwipsPerPixelY lngRegion = CreateEllipticRgn(0, 0, lngFormWidth, lngFormHeight) lngReturn = SetWindowRgn(Me.hWnd, lngRegion, True) End Sub |
منبع:www.cesblog.ir
+ نوشته شده توسط CES در سه شنبه بیست و چهارم خرداد ۱۳۹۰ و ساعت
23:51 |
