Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Image Scan
Message
From
17/12/2002 16:59:29
Jim Harty
FL Dept Fin Services-Div of Rehab & Liq
Tallahassee, Florida, United States
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Title:
Image Scan
Miscellaneous
Thread ID:
00733893
Message ID:
00733893
Views:
67
I lose control of my vfp application after executing the startscan method.
The focus switches to another open window. How do I keep focus on the scanning application main window? I'm calling vfp executable from another vfp application. The scanning application has a main form with the activex control on it. Once scanning begins, the focus switches to the most recent open\active window
such as excel or email. I wish focus to stay on the scanning application until i have completed processing.
Below is the code for initiating the scan process.
with thisform.ImgScan1
*if .showselectscanner<>0 then

* create new file key for automatically naming the file
* thisform.generate_newfileno()

* check to see if scanner is available before proceeding
if .scanneravailable() then

.scanto=1
.multipage=.t.
*.pagecount=thisform.txtpagcnt.value
*.image = IMAGEPATH + ALLT(ThisForm.cbotempfiletype.value) + alltrim(newidkeyc) + ".tif"
.image = ImgPath + ALLT(ThisForm.cbofiletype.value) + alltrim(filenumber) + ".tif"
* start scanning...

.startscan()
*.scandone()
*goimgapp.switchfocus()
*.ScanUIDone()
* stop scanning...
*.stopscan()

* select image file and finalize update
* append unique scanned file to image lookup file

*thisform.save_scanning()

else
wait window "Scanner Not Available"
endif
*else
* wait window "Scanner Not Selected"
*endif
endwith
Next
Reply
Map
View

Click here to load this message in the networking platform