Sign in to follow this  
Followers 0
Jabberwock

Send command to process?

25 posts in this topic

Is it possible to directly communicate between processes? Send commands and such?


Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

StdoutRead

StdinWrite

StderrRead

were talking about 2 programs youve made correct? if not

controlsend, controlcommand, and controlclick could be of some use

Edit* forgot StderrRead

Edited by thatsgreat2345

Share this post


Link to post
Share on other sites

I just looked at these, and I really don't understand how you can send a command to a process you wrote with those, i am pretty much looking to send a command which executes a func, which dosn't have any way of being executed on the GUI


Share this post


Link to post
Share on other sites

if you provide some code it would be greatly appreciated, but the thing is one program runs the other one, which when run you open up lines that you can send whatever you want and if you have both reading whats being sent on these lines and if it sends whatever u want it to send and with an If statement you can easily call a function , im curious as to how a program you made you are unable to call a function....

Share this post


Link to post
Share on other sites

Never said i was unable to call the function, just said i didn't understand how that could, it's 1 program, using _Singleton to detect if already loaded then send a command to execute a func.


Share this post


Link to post
Share on other sites

_Singleton makes sure the program that you have that function in is only running one process of it, so im just confused on what function you are sending to execute what thus why i said post your code

Share this post


Link to post
Share on other sites

Singleton can serve many purposes, It can exit if already running, or do whatever you want,

If _Singleton("test\test", 1) = 0 Then

blahblah to proccess

Exit

EndIf


Share this post


Link to post
Share on other sites

turtles


[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

yes but what im not understandign is why you dont go just kill the other process and call the function you need to call

Share this post


Link to post
Share on other sites

because my script has user input in it? that's just like saying, kill notepad & start a fresh one!


Share this post


Link to post
Share on other sites

because my script has user input in it? that's just like saying, kill notepad & start a fresh one!

Your Ebonics is amazing... Did you have to practice long at it, or does it come naturally for you?

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

this topic has strayed off point, if it's not possible say No. don't try to think of other ways to get it done, I have thought of many my self, but this would be the most effective if possible.


Share this post


Link to post
Share on other sites

If ProcessExists("NOTEPAD.EXE") Then
    ProcessClose("NOTEPAD.EXE")
    Run("NOTEPAD.EXE")
EndIf

dude your all over the board here with what you want

Are you kidding me? In no way did i even ask to do that....

Share this post


Link to post
Share on other sites

Can you state specifically in "steps" what you are trying to accomplish. I've tried to give subtle hints that you make absolutely no sense, but I guess you got that as much as I understand your request.

If you want to "communicate" with a process, you were give the answer the first time.

If you need something else, then you'll have to re-write your first executable to perhaps look in the registry/an ini/ a text file for something specific that your other process wants it to do.

If it's something other than that... Start over with what I requested above.


[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

because my script has user input in it? that's just like saying, kill notepad & start a fresh one!

its called showing an example of what you said your program is like if you want userinput then here you go

#include <GUIConstants.au3>
$Form1 = GUICreate("KILL", 354, 39, 193, 115)
$kill = GUICtrlCreateInput("", 24, 8, 273, 21)
GUISetState(@SW_SHOW)
While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_EVENT_CLOSE
            Exit
        Case GUICtrlRead($kill) = "kill"
            If ProcessExists("NOTEPAD.EXE") Then
                ProcessClose("NOTEPAD.EXE")
                Run("NOTEPAD.EXE")
                GUICtrlSetData($kill,"Notepad refreshed")
            Else
                GUICtrlSetData($kill,"Notepad Not Running")
            EndIf
    EndSelect
WEnd

Share this post


Link to post
Share on other sites

I've already said what I want to do, and I do not want any help from you Smoke_N, you're a fucking idiot...And Ebonics? are you "SmOke_N" crack?


Share this post


Link to post
Share on other sites

#18 ·  Posted (edited)

wow you've effectively ruined your status with one of the most high recognized people on this entire forum. CONGRATS

Edited by thatsgreat2345

Share this post


Link to post
Share on other sites

I've already said what I want to do, and I do not want any help from you Smoke_N, you're a fucking idiot...And Ebonics? are you "SmOke_N" crack?

;)

You know, I wondered what was wrong with you... and after I read this post that I worked dilligently to help you on: http://www.autoitscript.com/forum/index.php?showtopic=30619 I couldn't figure out why....

UNTIL.... I saw your true colors: http://www.autoitscript.com/forum/index.php?showtopic=32116 here... Calling me an idiot :lmao: Pot calling the kettle black more like it.


[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

i ham sofa king we Todd did -- keep saying that out loud untill you understand.


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