balala wrote:This command will sleep the computer only if you've disabled the hibernation. Otherwise it will hibernate it.
An alternative way, which is always working, would be to use the NirCmd little app, available here. If you want to try it, download it and use a this kind of command: IfAboveAction=["#@#nircmd.exe" "standby"] (obviously you have to copy the downloaded nircmd.exe into the @Resources folder).
fonpaolo wrote:I can suggest you to use NirCmd, then you don't have to worry if hibernation is enabled or not, choose to enable NirCmd to put your computer to sleep and also use hibernate when you need it.
As a side note, there is a version for 32 and a 64 bit of this program.
Brilliant. Well then I'd say that my request for help has resulted in a resounding success!
Thank you all for your help, what a fantastic community
this code doesn't work for me. I'm new to the whole rainmeter community, so i dont know how to implement it. Would you mind pointing me in the right direction on what to do? What do I need to use for the plugin, because the NowPlaying is outdated.
rainnoob wrote: ↑January 3rd, 2020, 7:33 pm
this code doesn't work for me. I'm new to the whole rainmeter community, so i dont know how to implement it. Would you mind pointing me in the right direction on what to do?
Which code doesn't work for you anymore? This topic is more than four years old, so it's extremely old, I definitely don't have the code which doesn't work for you, so you should post it please.
rainnoob wrote: ↑January 3rd, 2020, 7:33 pm
What do I need to use for the plugin, because the NowPlaying is outdated.
NowPlaying is definitely NOT outdated, just it's not anymore a plugin, but an internal measure.
i changed the playername to windows media player and the config to the monstercat-visualizer\Song Information.
What I did is made a new skin and put this code in there and then loaded it.
rainnoob wrote: ↑January 3rd, 2020, 8:59 pm
i changed the playername to windows media player and the config to the monstercat-visualizer\Song Information.
To use Windows Media Player with NowPlaying measures you have to use the PlayerName=WMP option into the parent NowPlaying measure. Set it this way to get the measure working.
Does it work now?
balala wrote: ↑January 3rd, 2020, 9:04 pm
To use Windows Media Player with NowPlaying measures you have to use the PlayerName=WMP option into the parent NowPlaying measure. Set it this way to get the measure working.
Does it work now?
This is correct, right?
I set my sleep to 1 minute for testing and nothing happened.
Last edited by balala on January 3rd, 2020, 9:18 pm, edited 1 time in total.
Reason:Please use <code> tags whenever are you posting code snippets, not <Snippet>. It's the </> button.
rainnoob wrote: ↑January 3rd, 2020, 9:14 pm
This is correct, right?
No, it's not. There are a few problems:
As said, since NowPlaying isn't anymore a plugin, but a measure and as such, you don't have to add the .dll extension into the Measure option (use Measure=NowPlaying instead of Measure=NowPlaying.dll).
The [UnloadIfNotPlaying] measure returns a numeric value, 0 if the player is closed and 1 if it is open. In such cases it is much better to use not IfMatch condition checking, but IfCondition (see below).
Finally, there are two more issues, which don't prevent the code to properly work (as previous two issues), but have to be said:
You can't disable a meter, just a measure. That's why the Disabled=1 option added to the [RequiredMeter] meter is completely useless. Remove it. Measures can be disabled or enabled, while meters can be shown or hidden.
In fact in most cases, the !ActivateConfig bang requires two parameters: the name of the config AND the name of the file of skin you'd like to activate. For !DeactivateConfig the name of the config is completely enough, but for !ActivateConfig is better to specify the name of the file too. It does work even if you don't specify it, loading the first file, if in the specified config are more skin files, but it definitely is better to give a filename as well. I added Left.ini as filename, you have to decide which one would you like to load, Left.ini, or Right.ini.