Re: help with autoit

  • From: Harmony Neil <harmony.neil@xxxxxxxxx>
  • To: programmingblind@xxxxxxxxxxxxx
  • Date: Sun, 02 Oct 2011 14:21:35 +0100

On 01/10/2011 23:57, Nikola Stojsic (NS studios) wrote:
Hello people.

I'm using autoit and I created something easy.
I have a problem, when I call a key (_isPressed function), it doesn't matter
am I in the program's window or not. And that's my problem, I've put a space
key for saying something, and when I'm in the program's window, or in the
e.g. windows explorer, it will do same thing. I've tried to put blockInput
(1) and (0) but it scrooded my keyboard.
Here's my code:

Block quote
#Include<Misc.au3>
#noTrayIcon
guicreate("milioner")
GuiSetState()
$OJfw = ObjCreate ("jfwapi")

if winActive ("milioner") then
while 1
$KeyPressed = 0
GuiSetState()
if _ispressed("1B") and $keypressed = 0 then
$keypressed = 1
exit
$KeyPressed = 0
endIf
If not _ispressed("1B") then
$KeyPressed = 0
endIf

if _ispressed("20") and $keypressed = 0 then
$keypressed = 1
$OJfw.saystring("welcome to the milioner game! Created by NS studios!", 2)
$KeyPressed = 0
endIf
If not _ispressed("20") then
$KeyPressed = 0
endIf
wend
endIf
if winActive ("milioner") == 0 then

endIf
block quote end

thanks in advance, and hope someone will help me.

Nikola Stojsic (NS studios)
e-mail: ns.studios1@xxxxxxxxx
skype: nikola.stojsic
aim: nikolastojsic
web site: http://www.nsstudios.tk


__________
View the list's information and change your settings at
//www.freelists.org/list/programmingblind

Hellow Nick,
just to let you know, your message came through on the list just fine. You asked me off list to let you know, so thought I'd reply.
Hope that helps,
Harmony.
__________
View the list's information and change your settings at //www.freelists.org/list/programmingblind

Other related posts:

  • » help with autoit- Nikola Stojsic \(NS studios\)
  • » Re: help with autoit - Harmony Neil