Welcome Guest.   Make a donation to an author on the site July 30, 2014, 06:11:14 AM  *

Please login or register.
Or did you miss your validation email?


Login with username and password (forgot your password?)
Why not become a lifetime supporting member of the site with a one-time donation of any amount? Your donation entitles you to a ton of additional benefits, including access to exclusive discounts and downloads, the ability to enter monthly free software drawings, and a single non-expiring license key for all of our programs.


You must sign up here before you can post and access some areas of the site. Registration is totally free and confidential.
 
The N.A.N.Y. Challenge 2014! Download dozens of custom programs!
   
   Forum Home   Thread Marks Chat! Downloads Search Login Register  
Pages: [1]   Go Down
  Reply  |  New Topic  |  Print  
Author Topic: Farr Alias: nircmd alias  (Read 17099 times)
jgpaiva
Global Moderator
*****
Posts: 4,710



Artificial Idiocy

see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« on: July 27, 2007, 08:48:06 AM »

Here's an alias that uses nircmd to do several useful functions smiley



Here's the table describing this alias:

CommandDescriptionExample
cmdList all the commandscmd
ScreensaverStart your Screensaverscreensaver
MonitorTurn your monitor on or offMonitor on or Monitor off
LockPcLock your computer (the same as pressing windows+L)LockPc
Set ResolutionSet the resolution of your computer (width, height and depth)SetRes 800 600 32
ChangeVolumeIncrease or Decrease the master volume of your computer (varies from 0 to 65)ChangeVol +10 or ChangeVol -10
MuteToggle the mute status the computer soundmute or unmute
RebootRestart the computerReboot or Restart
ShutdownShutdown computerShutdown or PowerOff
StandbyGet the computer in standby stateStandby
LogoffLogoff from the current sessionLogoff

Note: Everything assigned in bold is a farr keyword. If you find any keyword is too long, just type part of it, then when it's the first result, press tab to autocomplete.

* nircmd.zip (77.19 KB - downloaded 681 times.)
« Last Edit: November 01, 2009, 09:48:26 AM by jgpaiva » Logged

lanux128
Global Moderator
*****
Posts: 6,087



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #1 on: July 28, 2007, 03:04:45 AM »

nice work, jgp.. thumbs up i also would like to propose that a child board for Farr's aliases & plugins would make it easier to locate them.. smiley
Logged

mouser
First Author
Administrator
*****
Posts: 33,183



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #2 on: July 28, 2007, 03:09:07 AM »

good point lanux, though i am in the process of building a new farr2 page, and here is one of the subpages:
http://www.donationcoder....re/Mouser/findrun/addons/

probably still a good idea to make a child board dedicated to such things.
Logged
lanux128
Global Moderator
*****
Posts: 6,087



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #3 on: July 28, 2007, 03:27:57 AM »

i forgot that you're in the midst of building a Farr2 page, mouser.. btw, that page looks cool.. smiley
Logged

davidma22
Supporting Member
**
Posts: 20

View Profile Give some DonationCredits to this forum member
« Reply #4 on: May 29, 2008, 12:21:27 PM »

Sorry, I know this thread is kind of old, but could someone please explain how to install this plugin? It would really help if these things came with readme's...

Thanks.
Logged
tomos
Charter Member
***
Posts: 8,366



see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #5 on: May 29, 2008, 02:54:51 PM »

Sorry, I know this thread is kind of old, but could someone please explain how to install this plugin? It would really help if these things came with readme's...

unzip - the zip has a nircmd folder already in it,
copy that folder into the AliasGroups/Installed directory plugin folder in the FindandRunRobot install folder
hope that makes sense!
Tom
« Last Edit: May 29, 2008, 03:42:45 PM by tomos » Logged

Tom
mouser
First Author
Administrator
*****
Posts: 33,183



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #6 on: May 29, 2008, 03:34:35 PM »

Not in the plugin directory, in the Aliases/Installed directory.
Logged
tomos
Charter Member
***
Posts: 8,366



see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #7 on: May 29, 2008, 03:44:18 PM »

Not in the plugin directory, in the Aliases/Installed directory.

sry, just read "plugin" & started typing smiley
Logged

Tom
mouser
First Author
Administrator
*****
Posts: 33,183



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #8 on: May 29, 2008, 04:16:32 PM »

in reality it will work in the Plugins directory too, but the proper place for it is as a subdirectory of AliasGroups/Installed.
Logged
davidma22
Supporting Member
**
Posts: 20

View Profile Give some DonationCredits to this forum member
« Reply #9 on: May 29, 2008, 08:54:24 PM »

Thanks guys. That's perfect. Easy enough. Like I said though it might not hurt for plugin writers to include a little readme file with the simple instructions. (Though it should also mention that you need to restart FARR for the plugin to take effect.)

Thanks again. Love this program.

EDIT: Quick question about this plugin. It has standby, but it seems to be missing a command to put the computer in Hibernate (which I use far more often.) Is there any way for me to add that myself? Thanks.
« Last Edit: May 29, 2008, 08:57:43 PM by davidma22 » Logged
nitrix-ud
Charter Member
***
Posts: 482

View Profile Give some DonationCredits to this forum member
« Reply #10 on: May 30, 2008, 02:00:00 AM »

it is not a plugin per se
it is only an alias Wink
Logged
mouser
First Author
Administrator
*****
Posts: 33,183



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #11 on: May 30, 2008, 02:06:22 AM »

Quote
it seems to be missing a command to put the computer in Hibernate (which I use far more often.) Is there any way for me to add that myself?

Yes.

This alias pack uses the commandline tool NirCmd from Nirsoft.
That tool does have support for sending the computer into hibernate mode.

So, all you need to do is add a new alias to the pack which calls NirCmd with commandline parameter to hibernate.

See if you can figure out how to do that yourself, since it would be a good learning experience -- if you can't, come back and we will help.

(ps. one way to make your life easier is to move the alias pack from the AliasGroups/Installed to AliasGroups/MyCustom while you edit it since that will allow you to edit it from within FARR).

And if you figure it out, please share it so we can add the new hibernation alias to the official alias pack.  Thmbsup
Logged
davidma22
Supporting Member
**
Posts: 20

View Profile Give some DonationCredits to this forum member
« Reply #12 on: May 30, 2008, 02:36:26 AM »

I did it!  Grin

Not exactly sure what the format for this should be, so I'll just copy/paste what I did. I copied the line for Standby, changed the right places so they said hibernate, used the same image (since windows uses the same one, it's just a slightly darker color), and changed the windows cmd command to Hibernate. Simple enough. (Tested it too, just in case. It works fine.) Thanks for the help and the push Mouser.

EDIT: Forgot to say what I named the Alias, but I guess people can name it whatever they want. Personally I prefer using "Sleep" since it's shorter and easier to type than "Hibernate".

Hibernate Computer | %ALIASDIR%nircmd.exe qboxcom "Do you want to Hibernate the computer?" "question" Hibernate /ICON=nircmd_icons\Standby.ico
« Last Edit: May 30, 2008, 02:38:37 AM by davidma22 » Logged
mouser
First Author
Administrator
*****
Posts: 33,183



see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #13 on: May 30, 2008, 02:37:44 AM »

good work and welcome to the FARR customization club  thumbs up
Logged
davidma22
Supporting Member
**
Posts: 20

View Profile Give some DonationCredits to this forum member
« Reply #14 on: May 30, 2008, 02:55:04 AM »

Thanks. Another question for ya. I added an alias that uses nircmd's emptybin function to empty my recycling bin, but I can't find the recycling bin image on my computer anywhere... any idea where I would look for that? Thanks.
Logged
Grorgy
Supporting Member
**
Posts: 820

see users location on a map View Profile Give some DonationCredits to this forum member
« Reply #15 on: May 30, 2008, 03:23:33 AM »

you can find most of the standard icons in windows\system32\shell.dll  at least thats where i found 'em  Wink
Logged
tomos
Charter Member
***
Posts: 8,366



see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #16 on: May 30, 2008, 03:34:06 AM »

Thanks. Another question for ya. I added an alias that uses nircmd's emptybin function to empty my recycling bin, but I can't find the recycling bin image on my computer anywhere... any idea where I would look for that? Thanks.

is it under
C:\WINDOWS\system32\shell32.dll  [missed your reply there Grorgy]
(I've messed around with my icons -got the Tango pack to replace all windows icons Kiss so not quite sure if that correct location)

I'm afraid the hibernate alias doesnt show for me -
I tried it in FARR as you recommended mouser
Duplicated Standby, changed name and added your alias David

I notice FARR options show Reboot & a bunch of others under the nircmd alias that dont show in FARR window - anyone got any ideas there?
« Last Edit: May 30, 2008, 03:36:12 AM by tomos » Logged

Tom
Grorgy
Supporting Member
**
Posts: 820

see users location on a map View Profile Give some DonationCredits to this forum member
« Reply #17 on: May 30, 2008, 03:35:43 AM »

oooops yeah like tomos says shell32   sorry  embarassed
Logged
tomos
Charter Member
***
Posts: 8,366



see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #18 on: May 30, 2008, 03:36:37 AM »

oooops yeah like tomos says shell32   sorry  embarassed

noo nooo, you got there first  cheesy
Logged

Tom
davidma22
Supporting Member
**
Posts: 20

View Profile Give some DonationCredits to this forum member
« Reply #19 on: May 30, 2008, 05:57:20 AM »

Hm. Did you move the nirCMD folder into your custom alias folder before you edited? Here's what I did exactly. I moved the folder over to my custom aliases (and then restarted FARR), chose the NirCMD aliases from the list (where Reboot, Standy etc are listed). Right-clicked, selected Add New Alias, called it "Sleep", used the result from my previous post, and restarted FARR again. After that it worked fine.

EDIT: Okay, I know what the problem is. I added my alias to the list without adding it to the CMD group. So when you type CMD, it doesn't show up, but if you just type "Sleep" or whatever you call it, it will still show up and run fine.
« Last Edit: May 30, 2008, 05:58:57 AM by davidma22 » Logged
davidma22
Supporting Member
**
Posts: 20

View Profile Give some DonationCredits to this forum member
« Reply #20 on: May 30, 2008, 06:02:02 AM »

Okay here's how to add it so that it shows up when you type CMD. In the list of NirCMD aliases, edit CMD. Down at the bottom, add this line.

Hibernate Computer | restartsearch Hibernate /ICON=nircmd_icons\Standby.ico

After that it will show up and run if you type CMD first. But like I said, it's much quicker just to type the alias name rather than type CMD first.
Logged
tomos
Charter Member
***
Posts: 8,366



see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #21 on: May 30, 2008, 06:22:04 AM »

Okay here's how to add it so that it shows up when you type CMD. In the list of NirCMD aliases, edit CMD. Down at the bottom, add this line.

Hibernate Computer | restartsearch Hibernate /ICON=nircmd_icons\Standby.ico

After that it will show up and run if you type CMD first. But like I said, it's much quicker just to type the alias name rather than type CMD first.

got that, thanks thumbs up
Logged

Tom
delwoode
Supporting Member
**
Posts: 142


see users location on a map View Profile Give some DonationCredits to this forum member
« Reply #22 on: November 01, 2009, 07:51:28 AM »

why all the files in the zipped folder?
apart from the nircmd.exe  there were 4 alias files
nircmd.alias
nircmd.alias~
nircmd.alias.bak
nircmd.alias.bak~
do I need all these?
also my antimalware program didnt like nircmdc.exe and removed it but it thought nircmd.exe was fine
Logged
jgpaiva
Global Moderator
*****
Posts: 4,710



Artificial Idiocy

see users location on a map View Profile WWW Read user's biography. Give some DonationCredits to this forum member
« Reply #23 on: November 01, 2009, 09:49:16 AM »

You're right, delwoode. I have removed the superfluous files, and removed the nircmdc.exe file (which wasn't being used anyway).
Logged

koro
Supporting Member
**
Posts: 7


View Profile Give some DonationCredits to this forum member
« Reply #24 on: December 13, 2009, 12:00:39 PM »

For those of you having problems with hibernate instead of suspend, I'd like to point out that you don't need nircmd to do this.
You can just create a new shortcut called "hibernate" and place it anywhere in the search path of FARR.
The command to be executed by the shortcut is the following:

%windir%\System32\rundll32.exe powrprof.dll,SetSuspendState Hibernate

For other options, you can create shortcuts like this:

For Shutdown: %windir%\System32\shutdown.exe -s
For Reboot: %windir%\System32\shutdown.exe -r
For Logoff: %windir%\System32\shutdown.exe -l
For Standby: %windir%\System32\rundll32.exe powrprof.dll,SetSuspendState Standby
Logged
Pages: [1]   Go Up
  Reply  |  New Topic  |  Print  
 
Jump to:  
   Forum Home   Thread Marks Chat! Downloads Search Login Register  

DonationCoder.com | About Us
DonationCoder.com Forum | Powered by SMF
[ Page time: 0.054s | Server load: 0.2 ]