[VB] vb 让图片反色

[复制链接]
梅雷工具箱发表于 2015-6-25 13:17:56 | 显示全部楼层 |阅读模式
vb 让图片反色

'声明
Private Declare Function BitBlt Lib "gdi32" (ByVal hDestDC As Long, ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal hSrcDC As Long, ByVal xSrc As Long, ByVal ySrc As Long, ByVal dwRop As Long) As Long

Option Explicit

'按下 Command1控件 名为Picture1的里的图形 变成反色
Private Sub Command1_Click()
Picture1.ScaleMode = 3
  
BitBlt Picture1.hDC, 0, 0, Picture1.ScaleWidth, Picture1.ScaleHeight, Picture1.hDC, 0, 0, vbDstInvert
End Sub
_____________________________________________________________________________ _

中磊UG二次开发教程 梅雷著 qq1821117007
学UG就上UG网 http://www.9sug.com/
就上UG网淘宝直营店
您需要登录后才可以回帖 登录 | 注册UG网 用百度帐号登录

本版积分规则