hpwNLAutoItDll released

Machine-specific discussion
Unix, Linux, OS X, OS/2, Windows, ..?

hpwNLAutoItDll released

Postby HPW » Wed Dec 31, 2003 4:06 pm

Just upload a import module for AutoIt on newLISP.

Download:
http://www.hpwsoft.de/anmeldung/html1/n ... LISP3.html


Imported functions:

AUTOIT_Sleep
AUTOIT_BlockInput
AUTOIT_ClipGet
AUTOIT_ClipPut
AUTOIT_DetectHiddenText
AUTOIT_IfWinActive
AUTOIT_IfWinExist
AUTOIT_IniRead
AUTOIT_IniWrite
AUTOIT_IniDelete
AUTOIT_LeftClick
AUTOIT_LeftClickDrag
AUTOIT_MouseMove
AUTOIT_MouseGetPosX
AUTOIT_MouseGetPosY
AUTOIT_RightClick
AUTOIT_RightClickDrag
AUTOIT_SetCapslockState
AUTOIT_SetStoreCapslockMode
AUTOIT_Send
AUTOIT_SetKeyDelay
AUTOIT_SetTitleMatchMode
AUTOIT_SetWinDelay
AUTOIT_Shutdown
AUTOIT_WinWait
AUTOIT_WinWaitActive
AUTOIT_WinWaitNotActive
AUTOIT_WinWaitClose
AUTOIT_WinHide
AUTOIT_WinRestore
AUTOIT_WinMinimize
AUTOIT_WinMaximize
AUTOIT_WinMinimizeAll
AUTOIT_WinActivate
AUTOIT_WinClose
AUTOIT_WinMove
AUTOIT_WinSetTitle
AUTOIT_WinGetActiveTitle
AUTOIT_WinShow
AUTOIT_WinMinimizeAllUndo

Edit: Link and headline
Last edited by HPW on Sat Feb 07, 2009 6:28 am, edited 3 times in total.
Hans-Peter
HPW
 
Posts: 1375
Joined: Thu Sep 26, 2002 9:15 am
Location: Germany

Postby nigelbrown » Wed Dec 31, 2003 8:00 pm

Thanks,
I've found auto-it very helpful automating some windows things in the past.
Nigel
nigelbrown
 
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Postby nigelbrown » Thu Jan 01, 2004 1:27 pm

Hi Hans-Peter,
I was looking at hpwAutoIt.lsp and thinking on
(define (allocate n)
(join(map(fn(x)" ")(sequence 1 n))))
for allocating space. For another approach other than the list operations
one could use pack viz
(define (allocate n)
(pack (string "s" n) " "))
which gives one space followed by n-1 nulls in a string buffer.
This buffer seems to work for the AUTOIT_ClipGet function.
I've not looked at newlisp source code to see how efficient pack
would be for this use.
Nigel
nigelbrown
 
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Postby nigelbrown » Thu Jan 01, 2004 1:38 pm

I remembered the timing function (time which shows relative times:

> (define (allocate n) (join(map(fn(x)" ")(sequence 1 n))))
(lambda (n) (join (map (lambda (x) " ") (sequence 1 n))))
> (time (allocate 50000))
110
> (define (allocate n) (pack (string "s" n) " "))
(lambda (n) (pack (string "s" n) " "))
> (time (allocate 50000))
0
>


Nigel
nigelbrown
 
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Postby HPW » Thu Jan 01, 2004 2:40 pm

Nigel,

Thanks for the suggestion.
Always very welcome. Allocate was an quick suggestion from another thread here from Lutz, but he has stated that it is not the best performance code.

So your version is definatly welcomed.
I will put it in.
Hans-Peter
HPW
 
Posts: 1375
Joined: Thu Sep 26, 2002 9:15 am
Location: Germany

Postby Lutz » Thu Jan 01, 2004 4:24 pm

For timing I do:

(time (dotimes (x 1000000) (allocate 50))) => 4516 ; 4.5 micro seconds each

The overhead for (dotimes ...) is small:

(time (dotimes (x 1000000))) => 78 ; 78 nano seconds each

Lutz
Lutz
 
Posts: 5276
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California

Re: hpwNLAutoItDll released

Postby lyl » Thu Aug 01, 2019 3:00 am

when :
Code: Select all
(load "hpwAutoIt.lsp")

error message given:ERR: problem loading library in function import : "AutoItDLL.dll"
Why?

Ps:
newlisp v10.7.4, win7
AutoItDLL.dll, hpwAutoIt.lsp, newlisp.exe are in the same folder.
lyl
 
Posts: 33
Joined: Sun Mar 25, 2018 5:00 am

Re: hpwNLAutoItDll released

Postby HPW » Thu Aug 01, 2019 5:31 am

Hello,
Just tried it again:
newLISP v.10.7.4 32-bit on Windows IPv4/6 libffi, options: newlisp -h

> (load "hpwAutoIt.lsp")
AUTOIT_WinMinimizeAllUndo@1000161F
>


Do you have a 32bit newlisp installed?
(The thread and the dll is from 2004)

Regards
Hans-Peter
HPW
 
Posts: 1375
Joined: Thu Sep 26, 2002 9:15 am
Location: Germany


Return to newLISP and the O.S.

Who is online

Users browsing this forum: No registered users and 1 guest