I am creating a basic network panel for myself and have gotten pretty far with it. However, I have a bar meter that doesn't hide, even when I set the "Hidden=1". In other words, it starts off showing when I want it to be hidden at first. What could be the issue?
You must have some other action on a measure or something that is setting hideMeters to 0, or is otherwise unhiding that meter. I assure you that if you have
i found the problem (of course I find it when I post a problem, happens every time anywhere else).
So here is the thing: I have a measure that hides the bar meter if I have Ethernet plugged in (it would be pointless to have a signal bar if connected directly to it.) Looks like this:
Measure=Plugin
Plugin=SysInfo
SysInfoType=ADAPTER_TYPE
SysInfoData=Best
IfMatch=Ethernet
IfMatchAction=[!SetOption MeterNetworkSignalValue Text "Ethernet"][!SetOption MeterNetworkSignalValue X 304r][!HideMeter MeterNetworkSignalBar]
IfNotMatchAction=[!ShowMeter MeterNetworkSignalBar]
DynamicVariables=1
It is the "IfNotMatchAction" that is causing the problem. Of course, if for some reason I take the cable out, I want the bar meter to show back up. I am sure it is a simple solution, but how would I go about doing this? If needed I can provide all the code to make life easier and for you guys to test on your PCs
Seems to me you have a conflict between the #hideMeters# variable you are using on the meter, and the !ShowMeter you are using in the bang. The minute you unhide the meter with the bang, the meter is updated on the next skin update and obeys the current value of #hideMeters# and is hidden.
What you might want to do is use !SetOption to set the value of Hidden on that meter to either "0" or "#*hideMeters*#" as needed, so you avoid the conflict.
Okay, so I fixed the problem with the bar. I just took out the "IfNotMatchAction" that was causing the problem. Only thing now is that when I go from ethernet to wireless, The signal strength value Stays at "ethernet" and the bar stays hidden
The meter [MeterNetworkSignalValue] is never updated (and I just tried a IfNotMatchAction=[!UpdateMeter MeterNetworkSignalValue] with it), and the bar never shows back up.
i.e: Everything is working fine with wireless, I plug in the ethernet cord and everything still works fine, but when I go back to wireless, the connectivity value changes, but the signal strength does not (stays at "Ethernet"), and the bar stays hidden. How can I go about making the bar and value show back up?
If I didn't say it, thank you for the help, and your cooperation. Greatly Appreciated!
That didn't work the way you think it did. Now the bar never goes away. The #hideMeters# variable only changes when I click the minimize or maximize buttons. They hide (hideMeters=1) when I minimize, and show up (hideMeters = 0) when I maximize:
My point is that using both #hideMeters# on the meters and !ShowMeter in actions are a certain conflict. As soon as you show a meter, the variable causes it to be hidden.
You need to settle on one approach, either use the #hideMeters# variable on the meters in question and use a bang to change the value of the variable, or use !SetOption and / or !SetOptionGroup to set the value of the Hidden option on meter(s) as you want. I don't think you want to use both.
In any case, STOP using !ShowMeter / !HideMeter. Those are the wrong way to come at this. They conflict with the way you are setting Hidden on the meters.
I got it. I took out the !ShowMeter, !HideMeter (Like you suggested) and just put OnChangeAction=[!ToggleMeter MeterNetworkSignalBar,probably not exactly what you would have liked, but it gets the job done.
If I didn't say it, thank you for the help, and your cooperation. Greatly Appreciated!