Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Emulating Keyboard
Message
From
31/03/2005 15:09:09
Ariel Müller
Müller & Asociados S.R.L.
Córdoba, Argentina
 
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 6
OS:
Windows 2000
Miscellaneous
Thread ID:
01000261
Message ID:
01000442
Views:
18
This it is I code in form:
objForm = createobject("form1")
objForm.show
read event

define class form1 as form
	top = 0
	left = 0
	height = 250
	width = 375

	add object cmdQuit as commandbutton with ;
		top = 168, left = 156, height = 27, width = 84, caption = "Exit", name = "cmdQuit"

	add object txtgetdata as textbox with ;
		value = "", height = 23, left = 132, top = 60, width = 132, name = "txtGetData"

	procedure init
		*--
		*-- I execute the program that reads com port. I use CreateProcess function API
		*-- Within "readcomm.exe" I use the Keyboard command to send the characters 
		*-- reading of com port.
		*--
		local obj
		obj = createobject("backgrnd.backgrnd")
		obj.backgrnd("readcomm.exe")
		*-- The program "readcomm.exe" is open and reads com port constantly in background.
	endproc

	procedure cmdQuit.click
		clear events
		clear dlls 
		thisform.release
	endproc
enddefine
Previous
Reply
Map
View

Click here to load this message in the networking platform