General information
Category:
Coding, syntax & commands
Title:
How to code this inVFP ??
Hi,
I have a sample code which wrote in VB. I wish to convert it into VFP.
Below is the VB Code :
Declare Function TWAIN_AcquireToFilename Lib "EZTW32.DLL" (ByVal hwndApp%, ByVal bmpFileName$) As Integer
Declare Function TWAIN_SelectImageSource Lib "EZTW32.DLL" (ByVal hwndApp&) As Long
Declare Function TWAIN_AcquireToClipboard Lib "EZTW32.DLL" (ByVal hwndApp As Long, ByVal wPixTypes As Long) As Long
Declare Function TWAIN_IsAvailable Lib "EZTW32.DLL" () As Long
Declare Function TWAIN_EasyVersion Lib "EZTW32.DLL" () As Long
TWAIN_SelectImageSource (Me.hWnd)
s% = TWAIN_AcquireToFilename(Me.hWnd, "c:\temp.bmp")
If s% = 0 Then
Picture1.Picture = LoadPicture("c:\temp.bmp")
Kill "c:\temp.bmp"
Else
GoTo BadScan
End If
Clipboard.Clear
If TWAIN_AcquireToClipboard(Me.hWnd, nPixTypes) = 0 Then MsgBox "No image was acquired or transfer to the clipboard failed.", vbInformation, ""
BadScan:
MsgBox "Scan has been aborted", vbInformation, ""
Question :
1. how to code the (Me.hWnd) in VFP?
2. how to call the clipboard in VFP ?
Thanks
kengwen
3. What is mean by the s% ?
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only