Luigi Posted November 12, 2014 Share Posted November 12, 2014 I need comunicate an aplication running on local user with other application runing on local administrator. My first option is use TCP/TCPSend/TCPReceive. Works fine, until now... I have (and I will) user lock session and another start a new logon in the same machine, I have one application server runing on local administrator and two or more application runing on local user... I know MessageHandler.au3 and like this, but does not work to talk between applications in diferents accounts. There are another option to TCP for this situation? Visit my repository Link to comment Share on other sites More sharing options...
jdelaney Posted November 12, 2014 Share Posted November 12, 2014 (edited) Easiest route...have a common dir...in that dir, add user dirs. Have each session create files in their specific dir, with whatever your message is. Have your base script loop for, and read those files, and do whatever is needed. Or, just have them all output to one dir, as an ini|xml|etc, and logically set values to know where it's coming from, and what to do. Edited November 12, 2014 by jdelaney Luigi and Xandy 2 IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window. Link to comment Share on other sites More sharing options...
Luigi Posted November 12, 2014 Author Share Posted November 12, 2014 I like this, I will try it. Thank you again @jdelaney. Easiest route...have a common dir...in that dir, add user dirs. Visit my repository Link to comment Share on other sites More sharing options...
jguinch Posted November 12, 2014 Share Posted November 12, 2014 You can search for the MailSlot UDF Spoiler Network configuration UDF, _DirGetSizeByExtension, _UninstallList Firefox ConfigurationArray multi-dimensions, Printer Management UDF Link to comment Share on other sites More sharing options...
Luigi Posted November 12, 2014 Author Share Posted November 12, 2014 @jguinch, I see the Trancexx's UDF, thanks. Visit my repository Link to comment Share on other sites More sharing options...
Rockerfeller Posted November 13, 2014 Share Posted November 13, 2014 You could also use the registry. Link to comment Share on other sites More sharing options...
Luigi Posted November 13, 2014 Author Share Posted November 13, 2014 (edited) I follow the @jdelaney's tip, and write this little code: You need 4 files: a) nssm.exe at http://nssm.cc/download b] JSMN.au3 at https://github.com/ez2sugul/stopwatch_client/blob/master/JSMN.au3 c) server.au3 server.au3 d) client.au3 client.au3 STEPS a) compile server.au3 b] run server.exe as service b.1) WIN+R b.2) cmd b.3) go to folder where the files are b.4) nssm.exe install aaa_service (or other name) b.5) nssm.exe start aaa_service c) run client.au3 (compiled or not) If you run client.au3 without server.exe is running? Nothin is happend, you click on key and nothing is happend. When server.exe is runing? You click a button, the script read a handles's key, generate a Scripting.Dictionary, transform it in json and convert to binary, then... save at ini file. The server read ini file, check if are something data, read it, transform from binary to string, the string convert to json, read a key handle, choose a random color and random time to block a key. Take this Scripting.Dictionary, convert to json, convert to binary, and write ini file at user name in section 'received'. The client read ini file, detect the data, read it, write your received as "". The data is transformed from binary to string, the string to json (Scripting.Dictionary). Colored the key and block it for some time. Why convert the json in binary? Simple, because I use special characters. English is not my native language. I need encode this special characters. The easy way is use StringToBinary. The choose color and time, is made by server.exe. Client.exe take this data and execute. Perfectly meets my need for a bidirectional communication between two or more applications using a ini file as commom way. Edited November 13, 2014 by Detefon Visit my repository Link to comment Share on other sites More sharing options...
Luigi Posted November 13, 2014 Author Share Posted November 13, 2014 @Rockerfeller, some AVs can alert if you use registry, this happend in my company. Thank you for your reply. Visit my repository Link to comment Share on other sites More sharing options...
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