@Greg-Larsen Correct. They are optional should someone want to just use the triggercmd site to set off their actions but absolutely needed for Alexa/Google integration.
Posts made by Xander
-
RE: New commands not showing up as devices in the Alexa app
-
RE: Turning PC on (without WoL)
@Greg-Larsen If you want to add hardware, a $5 smart plug (Aliexpress) would do the job of your $25 (+hub) suggestion. Set the BIOS to turn on when power is provided and you're done.
I have my three monitors on one smart plug so when I say Good Morning to Alexa, she fires them up. I don't really need WoL so pressing the button is fine with me.
-
RE: Shutdown but computer starts few seconds later
@Joao-victor-0 That's not TriggerCMD causing the problem, it's another device connected to your PC that's causing it to power back on. If you run the command outside of TCMD, it will do the same thing.
Try unplugging your USB devices and see which one is reawakening your PC.
-
RE: Triggercmd doesn't install windows 64 bits
"2021-08-26 19:54:08 Program: About to install to: C:\Users\User\AppData\Local\Discord"
"2821-08 1-26 19:54:21) Apply 21 ApplyReleasesImpl: Updating shortcut C:\Users\User\Desktop\Discord.Ink"@Igor-Marinho Looks like you're installing Discord, not TriggerCMD.
-
RE: Shutdown command doesn't work on Windows Server
@matheus-venancio What is the actual command that you're using? And does it work from a cmd prompt?
-
RE: Turn On Notebook Display
@Bruno-Rafael Look through recent posts for NirCmd instructions. It can simulate key presses but I don't know that a virtual press will suffice.
If it does, simply create an Alexa routine with both actions (and you'd probably want to throw a Wait command in between)
-
RE: How to use Off Command
@Russ Sorry for the delayed reply; crazy week.
Background was the problem on the one part.
On the other, for some weird reason, Task Scheduler was renaming the actual .job from "SCoff" to "SC off" so that the path was wrong. Once I spotted that, I got it working.Just to check - I've been running the x86 version of TCMD on that PC for...years? Other than the updated .js, there's no newer version? The main DL is x64.
-
RE: How to use Off Command
@Russ D'oh. The link here showed it went to ...node.js so I downloaded from here but now it's clear that it was a page about it so I've DL'd it properly ️
That's back up and running.Question, though. I switched the command to use SCHTASKS to run a job of the same batch files to circumvent any UAC issues but SCoff doesn't work in either bat or task form. The cmd window -says- it's being called but no window is called. Any ideas?
[ {"trigger":"Users","command":"schtasks.exe /run /tn users","ground":"foreground","voice":"users"}, {"trigger":"Connect","command":"schtasks.exe /run /tn SCon","ground":"background","voice":"connect"}, {"trigger":"Disconnect","command":"schtasks.exe /run /tn SCoff","ground":"background","voice":"disconnect"}, {"trigger":"Remote","command":"schtasks.exe /run /tn SCon","offCommand":"schtasks.exe /run /tn SCoff","ground":"foreground","voice":"Remote","voiceReply":"Okay","allowParams":"true" }, {"trigger":"Reboot","command":"shutdown /r /t 10","ground":"foreground","voice":"reboot"} ]
In case I would need them as separate commands, I created the Connect/Disconnect commands which I think are fine but they don't show in the TCMD trigger page at all.
-
RE: How to use Off Command
@Russ That's probably it. The agent.js has a date stamp of Nov 2017. Closed tcmd, updated from your link (old was 23kb, new is 348kb. Quite the diff!)
But, on starting the batch file, I get an "unexpected token" error. It also overwrote my .json file but it was mostly the line above so I'll redo it if I need to. Swapped the old .js back and it runs so something is amiss.
SyntaxError: Unexpected token < at createScript (vm.js:80:10) at Object.runInThisContext (vm.js:139:10) at Module._compile (module.js:599:28) at Object.Module._extensions..js (module.js:646:10) at Module.load (module.js:554:32) at tryModuleLoad (module.js:497:12) at Function.Module._load (module.js:489:3) at Function.Module.runMain (module.js:676:10) at startup (bootstrap_node.js:187:16) at bootstrap_node.js:608:3
-
RE: How to use Off Command
@Russ I'm trying to setup an on/off command for some services. The PC is x86 so I'm just editing the JSON file.
Here's the line inside the JSON:
{"trigger":"Remote","command":"C:\Users\STICK10\Documents\SC on.bat","offCommand":"C:\Users\STICK10\Documents\SC off.bat","ground":"foreground","voice":"Remote","voiceReply":"Okay","allowParams":"true" },When I try to trigger it, it's only running the SC ON batch file, not the OFF. What's my error? Or do I need to set these as two different commands altogether?
Inside TCMD's cmd window:
{ trigger: 'Remote',
id: '____',
params: 'on' }
Running trigger: Remote Command: C:\Users\STICK10\Documents\SC on.bat
Reported: Command Ran
{ trigger: 'Remote',
id: '____',
params: 'off' }
Running trigger: Remote Command: C:\Users\STICK10\Documents\SC on.bat
Reported: Command Ran -
RE: Questions
@Russ I'm trying to get this to work on an old (out of date) Win10 micro-PC that's x86.
{"trigger":"Users","command":"schtasks.exe /run /tn users","ground":"background","voice":"users"},
Here's the command in the JSON file. If I run the schtasks from a command prompt, it works. If I try to trigger this, it doesn't. Am I missing some syntax?
(The goal is to run a batch file at c:\ which deletes a file in Program Files and replaces it with a backup.)
EDIT: Just needed to change it to Foreground ️
-
RE: Monitors wont turn off
@Contamiply You need a space after the .exe
C:\Windows\MultiMonitorTool.exe /TurnOff 0Every program/parameter works that way - Windows has to know where the program name ends and the parameters begin.
-
RE: Como usar o Nircmd?
@Russ Don't forget that if you run Nircmd without any parameters at all, it provides a button to copy it to c:\windows. It must be run with Admin privileges (Run box ... ctrl+shift+enter) though.
-
RE: Option for it to work only with the "task'', is it possible?
@kanashi横維 [Moved to General Discussion as this is not an Announcement]
-
RE: Opens the CMD window instead of the game
@MichealDean Did you read the first reply which the OP said worked?
This is a thread that's been dead for three years.
-
RE: WINDOWS settings to Alexa
Set your command to ms-settings:
Google can find you a list of sub commands (e.g. ms-settings:network) for any specific sections.
-
RE: How can I open an iPhone app from triggercmd?
@jsmr1360 Instead of talking to your computer, just talk to your phone. Sounds like you want to overcomplicate things.
-
RE: Como suspender o pc pela alexa?
"Edson, how did you turn on the suspended pc by alexa?"
@Magno-Diego PCs that have no power (e.g. hibernating) can't be woken by internal commands ... because they're off. If you have multiple PCs, you could look into Wake On Lan.
And, just so you know, once a PC is locked, there is -no- way to unlock it with commands. That's a security feature of Windows; always has been. -
RE: Skip the "Alexa, ask TriggerCmd" command?
@Dimo-Ninov All my commands show up as their own virtual devices. To hibernate my PC, it's just "Alexa, turn on Hibernate". I could also set up a Routine so all I have to say is "Alexa, Hibernate" and it'll turn on the device.