[解决办法] 参考以下步骤进行: 1、在窗体上拖放一个Flash控件,并加载你的SWF 2、设置窗体的BorderStyle=0,BackColor为需要屏蔽的颜色,注意这种颜色不要在SWF中使用。 3、调用API函数屏蔽窗体颜色,如以下代码所示: Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long) As Long Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (ByVal hwnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long Private Declare Function SetLayeredWindowAttributes Lib "user32" (ByVal hwnd As Long, ByVal crKey As Long, ByVal bAlpha As Byte, ByVal dwFlags As Long) As Long
Private Sub Form_Load() Dim rtn As Long rtn = GetWindowLong(hwnd, GWL_EXSTYLE) rtn = rtn Or WS_EX_LAYERED SetWindowLong hwnd, GWL_EXSTYLE, rtn SetLayeredWindowAttributes hwnd, VbRed,0, LWA_COLORKEY '这里屏蔽的为红色。VbRed可改为其他你想屏蔽的颜色 Sub