Last edited by balala on April 16th, 2021, 4:00 pm, edited 1 time in total.
Reason:Please use <code> tags whenever are posting code snippets. It's the </> button.
Windows 10 does a "hybrid" shutdown by default, which will not reset the system uptime when the system is restarted. You can solve this with code like this:
What Windows 10 does on shutdown is unload all running applications, unload the active user account, and then "hibernate" the actual core system. This is so it starts up MUCH faster later. So a better way of knowing how long it has been since a shutdown is to look at how long the active user account has been running.
Last edited by jsmorley on April 26th, 2021, 11:11 am, edited 1 time in total.
Reason:Please use the code tags for embedding your code. It's the </> button at the top.
KT Administrator wrote: ↑April 26th, 2021, 11:06 am
Can you please take a look at the code and give me a reply with a code that I can use?
As you see jsmorley says he added a background to the String meters. If the problem is the fact that the tooltips are not shown properly, this is caused by the fact that you have to hover the mouse over the lines of shown letters, which is not extremely easy.
To fix this add a SolidColor=0,0,0,1 option to both meters [MeterLabelUserUpTime] and [MeterUpTime]. This way the meters will properly react to mouse hovering and the tooltips will be shown.
Obviously you can use any not transparent color, 0,0,0,1 is just an example. Make sure the last (fourth) number is not 0. It is not visible, but mouse hovering works well with it.
Found out that you can not run 2 MesaureUpTime at the same time. So I had to put a hashtag in front of the first one I had - after that the code I have put together worked with your help.
If I have to show both MesaureUserUpTime and MesaureUpTime, then I have to show both, right? Like this:
Last edited by balala on April 27th, 2021, 8:43 am, edited 1 time in total.
Reason:Please use <code> tags whenever are posting code snippets. It's the </> button.
KT Administrator wrote: ↑April 27th, 2021, 7:46 am
Found out that you can not run 2 MesaureUpTime at the same time. So I had to put a hashtag in front of the first one I had - after that the code I have put together worked with your help.
Why couldn't you? They can be used, I doubt they couldn't be. However not sure how your code is like (supposing you were not talking about the posted code, since it has one single [MeasureUserUpTime] measure, which I suppose this is the measure you'd like to duplicate), so not sure what would you like to duplicate, give us (me) a few details, please.
KT Administrator wrote: ↑April 27th, 2021, 7:46 am
If I have to show both MesaureUserUpTime and MesaureUpTime, then I have to show both, right? Like this:
I suppose you are talking about the MesaureUserUpTime and MesaureSystemUpTime measures, because your code doesn't have a MesaureUpTime measure.
You can either use two string meters, or one single which shows the values of both measures. It's your decision. You've used two String meters ([MeterUserUpTime] and [MeterSystemUpTime]), but it can be done with one single such String meter as well. Please let me know if you don't know how but are interested.
Perhaps the confusion is with having two measures that use the same functionality. This is fine, you just need to be sure that they have different [SectionNames].
balala wrote: ↑April 27th, 2021, 9:03 am
Why couldn't you? They can be used, I doubt they couldn't be. However not sure how your code is like (supposing you were not talking about the posted code, since it has one single [MeasureUserUpTime] measure, which I suppose this is the measure you'd like to duplicate), so not sure what would you like to duplicate, give us (me) a few details, please.
I had two MesaureUpTime, but I changed the new one to MesaureSystemUpTime.
balala wrote: ↑April 27th, 2021, 9:03 am
I suppose you are talking about the MesaureUserUpTime and MesaureSystemUpTime measures, because your code doesn't have a MesaureUpTime measure.
You can either use two string meters, or one single which shows the values of both measures. It's your decision. You've used two String meters ([MeterUserUpTime] and [MeterSystemUpTime]), but it can be done with one single such String meter as well. Please let me know if you don't know how but are interested.
Thank you. I am interested to get the code.
Which Mesaure would yo recommend I should use? MesaureUpTime, MesaureUserUpTime or MesaureSystemUpTime? Or all?