Funny, I typed in Pete for Window 1, and Repete for window 2, but then Re appeared in the first window. It shouldn't do that until the name is entered and the initial message is sent. So, just a small glitch.
You might want to add either a _screenclick or min/restore routine so the windows trade focus. See the Keyword of the day link here:
https://qb64phoenix.com/forum/showthread.php?tid=1238
See my messenger code TCP/IP alternative to the _CLIPBOARD$ keyword in that thread.
I would recommending expanding _SCREENCLICK in that demo to recognize when a window is moved though. Obviously I can't get into that much detail in an explanation demo, but Windows API offers some pretty easy to make ways to tell QB64 where the top-left of your program window is located as well as using _SCREENY and _SCREENX in QB64. With that addition, you won't be blind clicking on your desktop if a window gets moved.
Also, you can use Win32 API to trade focus if you min/restore. That can be partially done with _SCREENICON, too. The WinAPI only example I have at my Messenger app at the QBasic Forum: https://www.tapatalk.com/groups/qbasic/t...39735.html
Fun stuff, glad you got yours working. If it plays nice with mine we start our own DOScord channel!
Pete
You might want to add either a _screenclick or min/restore routine so the windows trade focus. See the Keyword of the day link here:
https://qb64phoenix.com/forum/showthread.php?tid=1238
See my messenger code TCP/IP alternative to the _CLIPBOARD$ keyword in that thread.
I would recommending expanding _SCREENCLICK in that demo to recognize when a window is moved though. Obviously I can't get into that much detail in an explanation demo, but Windows API offers some pretty easy to make ways to tell QB64 where the top-left of your program window is located as well as using _SCREENY and _SCREENX in QB64. With that addition, you won't be blind clicking on your desktop if a window gets moved.
Also, you can use Win32 API to trade focus if you min/restore. That can be partially done with _SCREENICON, too. The WinAPI only example I have at my Messenger app at the QBasic Forum: https://www.tapatalk.com/groups/qbasic/t...39735.html
Fun stuff, glad you got yours working. If it plays nice with mine we start our own DOScord channel!
Pete