Интересует вопрос возможно ли картинки сохранять в jpg и как все же делать фото формы или элеметов формы?
Я так полагаю без хендлов тут не обойтись.
Мой исходный код:
- Код: Выделить всё
Private Declare Function GetDC Lib "user32" (ByVal hwnd As Long) As Long
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
Private Const SRCCOPY = &HCC0020
Private Sub Command1_Click()
h = GetDC(0)
BitBlt Picture1.hDC, 0, 0, Screen.Width, Screen.Height, h, 0, 0, SRCCOPY
Picture1.Picture = Picture1.Image
SavePicture Picture1.Picture, "C:\Test.bmp"
End Sub