Sign in to follow this  
Followers 0
mud409

simple script I need help with

13 posts in this topic

it seems so simple, I can't believe I can't figure out how to do it...

I've got this script executing the program and bringing it to the front but now I need it to press alt+F then N

I also want to input some text into an input box on the window that opens and press a button after but I need to figure out how to do the alt+f then n first...

any help is appreciated

Share this post


Link to post
Share on other sites



it seems so simple, I can't believe I can't figure out how to do it...

I've got this script executing the program and bringing it to the front but now I need it to press alt+F then N

I also want to input some text into an input box on the window that opens and press a button after but I need to figure out how to do the alt+f then n first...

any help is appreciated

Welcome to the forums :)

You will find the way to do it in the help file for Send

Send("!f") ;simulates Alt f

Send("n"); simulates n


Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.

Share this post


Link to post
Share on other sites

Send("!f") ;simulates Alt f

Send("n"); simulates n

Send("#r")
WinWaitActive("Run")
Send("c:\program.exe{Enter}")
WinWaitActive("Program")
Send("!f")
Send("n")

loads the program and then just sits there... if I do it with kb it works fine.

Share this post


Link to post
Share on other sites

works fine with notepad but when it comes to the program I'm trying to do it with it doesn't do anything... is there another way?

Share this post


Link to post
Share on other sites

works fine with notepad but when it comes to the program I'm trying to do it with it doesn't do anything... is there another way?

What is the program?

Share this post


Link to post
Share on other sites

mame32k v0.64

Share this post


Link to post
Share on other sites

mame32k v0.64

You'll probably find that Mame is active but not ready to receive the keystrokes when it starts as I think it polls your list of games on startup. You may need to test for the text that says polling of games is complete.

I'd love to start up Mame and have a look but I'm at work and frantic keyboard button pressing is frowned upon around here.... :)

Share this post


Link to post
Share on other sites

Game search 100% complete

what do I do with this?

Share this post


Link to post
Share on other sites

Game search 100% complete

what do I do with this?

Change the winwaitactive function and add the text....

WinWaitActive("NameInTitleBar","Game search 100% complete")

I'm going to be playing Mame after work today for sure... it's been years. Time for a bit of Galaga and Wonderboy.

Share this post


Link to post
Share on other sites

could you download mame32k and try this out with me when you get home?

Send("#r")
WinWaitActive("Run")
Send("c:\mame32k0.64en\mame2\mame32k.exe{Enter}")
WinWaitActive("Mame32k", "Game search 100% complete")
Send("!f")
Send("n")

still nothing

Share this post


Link to post
Share on other sites

still nothing

If you start up the program manually and wait for it to finishing polling roms the run the script

Send("!f")
Send("n")

does it do what you want?

Share this post


Link to post
Share on other sites

I suppose I should explain a bit of what I'm trying to accomplish here...

Mame32k has online support through kaillera. I'm trying to automate the process of setting up an online game so I can link individual games through autoit exe's to a front end (mamewah) on a arcade cabinet...

I also have about a billion other scripts I want to write to automate processes for this arcade cabinet but 1 step at a time...

Share this post


Link to post
Share on other sites

#13 ·  Posted (edited)

you know I tried removing the rest of the script and starting the game manually and it didn't work...

everything I try in mame32k doesn't seem to want to work...

I can get stuff to work no problem in other programs like notepad but when it comes to mame, nothing...

Edited by mud409

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0