Sign in to follow this  
Followers 0
layer

Run ("AIM.exe /paremeters?") or commands..

11 posts in this topic

How would I go about giving a command to AIM (instant message program) from AutoIt? I can do this in batch files, but not to sure how to do it in AutoIt... For example, in batch files, it would be something like

Batch

start aim:goim?screename=screenamehere&message=messagehere

So how could I do something like this in AutoIt??


FootbaG

Share this post


Link to post
Share on other sites



Ok, thank you CyberSlug, except now...I got this:

Run(@ComSpec & " /c start aim:goim?screename=Test&message=Test", "", @SW_HIDE)

It works and all, except for a little thing, two little things actually:

1: It brings up the AIM IM Window, but it doesn't type in the Screename, or the message...How come?

2: Is there a way to make the message=$variable&screename=$variable2 ????? Because if I can't then my program goes down the drain =/

Thanks for the help = D


FootbaG

Share this post


Link to post
Share on other sites

Thanks CyberSlug, but would there be a way to use the variables? Something like:

$test= MyScreename
$test2= MyMessage

aim:goim?screename=$test&message= $test2

If so, how?

Thanks. =D


FootbaG

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

I wonder if the help file would explain how to concatenate string literals and variables... nah, probably not, thats not something people would do in virtually every script they write.

Edit: Typo (Fixed).

Edited by Valik

Share this post


Link to post
Share on other sites

I don't get what you mean? Maybe because I'm having a Snapple...


FootbaG

Share this post


Link to post
Share on other sites

Also, one more thing...If I wanted to change the font color for the AIM font, would I change that in AutoIt or would I use the HTML to make the differen't color? Did I explain it good enough?


FootbaG

Share this post


Link to post
Share on other sites

Layer after some research this is what I came up with (BTW This took some extensive testing (1 hour) just to figure out how to make it accept the variables.

$screenname = "A screenname here"
$message = "This is a total test please work"

If StringInStr($screenname, " ") Then
   $screenname = StringReplace($screenname, " ", "+", 0, 0)
EndIf
If StringInStr($message, " ") Then
   $message = StringReplace($message, " ", "+", 0, 0)
EndIf

Run(@ComSpec & ' /c start aim:goim?screenname=' & '"' & $screenname & '&message=' & $message, '',@SW_HIDE)

The reason I replace all spaces with +'s is because that is how it is recommended. It also allows you not to have to mess with the quotation as much.

If you notice right in the middle of the run statement I had to put a '"' before the screenname. Putting that in is the only way I have found to make the variables work.

Let me know if you have any questions,

JS


AutoIt Links

File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out.

ComputerGetInfo UDF's Updated! 11-23-2006

External Links

Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more)

Share this post


Link to post
Share on other sites

Hah! Thank you JS sooooooooooooooooooooooooooooooooooooo much for your time =) I really appreciate it!


FootbaG

Share this post


Link to post
Share on other sites

Not a problem, glad I could help.

JS


AutoIt Links

File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out.

ComputerGetInfo UDF's Updated! 11-23-2006

External Links

Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more)

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