FAQFAQ   SearchSearch   UsergroupsUsergroups   RegisterRegister   ProfileProfile    Log inLog in   RSS Feed

REQ: Script to run external shortcut

 
Post new topic   Reply to topic    Salling Software Forums Forum Index -> Scripting Salling Clicker for Windows
View previous topic :: View next topic  
Author Message
Deveron28
Newbie


Joined: 08 Apr 2009
Posts: 6

PostPosted: Wed Apr 08, 2009 9:11 pm    Post subject: REQ: Script to run external shortcut Reply with quote

Hi Guys....

Can someone possibly create an script for use with this app:

http://www.rtsoftwares.com/TurnOffMonitor/Turn-Off-Monitor.htm

If someone can help them, I'll give them the fully registered version of this software:

thanks
Back to top
View user's profile Send private message
Deveron28
Newbie


Joined: 08 Apr 2009
Posts: 6

PostPosted: Thu Apr 09, 2009 5:55 pm    Post subject: Reply with quote

Please help...

Thanks
Back to top
View user's profile Send private message
jae_63
Senior Member


Joined: 29 Mar 2006
Posts: 79
Location: Bethesda, MD

PostPosted: Fri Apr 10, 2009 7:55 pm    Post subject: Reply with quote

If you just want to blank the screen, this code snippet works for me. I use this in my local copy of the Pandora script.



[code:1]function runScreenSaver()
{
var wsh = new ActiveXObject('WScript.Shell');
if (wsh)
wsh.Run("%windir%\\System32\\scrnsave.scr");
}
[/code:1]
Back to top
View user's profile Send private message
Deveron28
Newbie


Joined: 08 Apr 2009
Posts: 6

PostPosted: Sat Apr 11, 2009 7:03 pm    Post subject: Reply with quote

Great stuff jae_63,

Is it possible to turn off my monitor & also turn it back on with a click/shortcut??

Thanks
Back to top
View user's profile Send private message
jae_63
Senior Member


Joined: 29 Mar 2006
Posts: 79
Location: Bethesda, MD

PostPosted: Mon Apr 13, 2009 4:29 pm    Post subject: Reply with quote

[quote="Deveron28"]Great stuff jae_63,

Is it possible to turn off my monitor & also turn it back on with a click/shortcut??

Thanks[/quote]

I've shown you (above) how to turn the monitor off in your script. You can turn it on in your script by having it nudge the mouse a bit. Read about SendMouseEvent(). Note that you can nudge it twice; once to get Windows' attention, and a second time to move it back to where it was so you don't confuse the user.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Salling Software Forums Forum Index -> Scripting Salling Clicker for Windows All times are GMT + 2 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group