hakpersson Posted June 1, 2023 Posted June 1, 2023 Hi! Fairly new to AutoIt. Using it for smaller tasks in a custom Commodore C64 BBS setup running och Windows 10 (PC). For the interface I use ConEmu (custom C64 font). Using WinVice and I´ve build this with hybrid between batch and python. Currently im using a split in ConEmu using the -new_console switch to build the interface. One of the windows is running WinVice for the C64. It´s all working fine, but the BBS program has this "screen saver" and if you press {space} approx every 4:th minute this can be avoided. Thats what I want to achives. At the same time there is a main menu that has to be reachable all of the time. The focus when loaded is in the main menu. The main menu consists of commands outside the C64 BBS setup. This is for managing other stuff not direcly connected to the emulated C64 in the WinVice. If I have focus on the WinVice window/tab in ConEmu I can manage to send {space} with the script that I have attached. It checks a logfile to see if the telnet port reports LISTENING or ESTABLISHED. If ESTABLISHED it will not send {space}. The problem is that I cannot send {space} to the window/tab in ConEmu if it does not have focus. That poses a problem since the Sysop/User needs to be able to user the main menu all of the time to control other stuff. Can someone please point me in the right direction here? I have really been trying with for example ControlSend, SendMessage, WinAPI_PostMessage (with hex) etc. Can't get it to work unless the WinVice window has focus. I have also tried the option in AutoIT called "AutoItSetOption (WinSearchChildren, 1)". Much appriciated! SpaceShrimp-v1.2b.au3Fetching info...
hakpersson Posted June 1, 2023 Author Posted June 1, 2023 PS. Noticed that in the script attached that I replaced {space} with C just for testing.
argumentum Posted June 1, 2023 Posted June 1, 2023 I would load all that setup into a VM and keep it in focus and do the Send("{SPACE}"). That you'd solve the problem. What say you ? Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting.
hakpersson Posted June 1, 2023 Author Posted June 1, 2023 VM is one thing. But the focus problem in not associated with that. The problem is sending {space} keystroke "Space" to a windows in ConEmu that does not have focus.
argumentum Posted June 1, 2023 Posted June 1, 2023 I figure that the pic. is of 2 windows, one the BBS in ConEmu and the other that could run on another VM. If that is so then run 2 VMs. My 2 cents Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting.
Nine Posted June 1, 2023 Posted June 1, 2023 Maybe block all inputs, give focus to the ConEmu window, enable kb, send space, disable kb, give focus to previous window, enable all inputs ? That should only take a fraction of a second. “They did not know it was impossible, so they did it” ― Mark Twain Reveal hidden contents Block all input without UAC Save/Retrieve Images to/from Text Monitor Management (VCP commands) Tool to search in text (au3) files Date Range Picker Virtual Desktop Manager Sudoku Game 2020 Overlapped Named Pipe IPC HotString 2.0 - Hot keys with string x64 Bitwise Operations Multi-keyboards HotKeySet Recursive Array Display Fast and simple WCD IPC Multiple Folders Selector Printer Manager GIF Animation (cached) Debug Messages Monitor UDF Screen Scraping Round Corner GUI UDF Multi-Threading Made Easy Interface Object based on Tag
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now