bitblt必须知道位图的width和height,这个从哪里能得到?

解决方案 »

  1.   

    http://www.mvps.org/vbvision/_samples/MDI_Background_Demo.zip
    MDI Background Demo.zip (25KB)
       This project shows how you can use memory device contexts to create pictures that can be assigned to the picture property of a VB MDI parent form.  The project contains routines to stretch a bitmap across the background of the form and center a bitmap on top of a background as well as a routine for tiling a bitmap onto the background.  It also contains code to draw transparent bitmaps that is used when overlaying a foreground bitmap onto the background.  This project replaces a previous demo that used subclassing to attain a similar result.  The routines in this project are generic enough that they can be used with any VB form or control that has a picture property.
      

  2.   

    谢谢zyl910(910:分儿,我来了!),刚才我也想到了使用内存设备,如果不是先上来看看,就得写一大堆代码了。