应该是做成图形式的窗口
不过DoTransparency过程没定义,能否贴出来,我觉得挺有用的

解决方案 »

  1.   

    好的。不过不是我写的。
    Public Sub DoTransparency(TheForm As Form)
    ' TheForm:  The form you want to be rounded rectangle shape
        
        Dim TempRegions(6) As Long
        Dim FormWidthInPixels As Long
        Dim FormHeightInPixels As Long
        Dim a
        
    ' Convert the form's height and width from twips to pixels
        FormWidthInPixels = TheForm.Width / Screen.TwipsPerPixelX
        FormHeightInPixels = TheForm.Height / Screen.TwipsPerPixelY
        
    ' Make a rounded rectangle shaped region with the dimentions of the form
        a = CreateRoundRectRgn(0, 0, FormWidthInPixels, FormHeightInPixels, 24, 24)
        
    ' Set this region as the shape for "TheForm"
        a = SetWindowRgn(TheForm.hWnd, a, True)
    End Sub