It is currently April 25th, 2024, 4:01 pm

IfCondition Show/Hide MeterImage or MeterGroup

Get help with creating, editing & fixing problems with skins
neo.nemek
Posts: 36
Joined: February 11th, 2023, 7:52 am

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by neo.nemek »

Thank you for answering and for your attention SilverAzid, because the variable that you mention WiFiInterfaceID was not declared and after your observation I included it in the Skin, I know that I have the code very wrong in part due to the fact that I am like crazy looking for a solution to the problem of Wi-Fi signal.
You might want to carefully look at the Rainmeter measures on the debug window (Rainmeter > About > Skins > (your skin)). Make sure your measures are enabled and returning values, and watch what happens when you connect/disconnect your adapters.
Yes I do, I mostly rely on what I see in the Rainmeter debugger, I'm going to try your Skin WirelessMeter Pro, maybe yours doesn't have this signal problem and it updates correctly, I'll tell you something in a while.

I already tried your mask after restarting my computer and with the network connection established by Ethernet I deactivated the Ethernet and connected to my network by wifi and your signal bar also stays at 0% and my SSID does not appear, it seems that your WirelessMeter It also has that problem at least on my computer with my Wifi Network
neo.nemek
Posts: 36
Joined: February 11th, 2023, 7:52 am

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by neo.nemek »

I have uninstalled Rainmeter and reinstalled in case the error was in Rainmeter and I do not believe that the 3 Skins that I have in test give SSID 0 as a result after changing from Active Ethernet -> Deactivate Ethernet -> Active Wifi and the 3 Skins give Quality=0 SSID=0
SSID-0.jpg
The problem is not from my code because no Skin is updated correctly on my computer with my Wifi interface, only if the Skin is refreshed manually The Quality parameter shows the correct Wifi signal and the correct SSID, Now we all have to think about why it happens and how to solve it. jajajajaja ;-)
You do not have the required permissions to view the files attached to this post.
User avatar
SilverAzide
Rainmeter Sage
Posts: 2605
Joined: March 23rd, 2015, 5:26 pm

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by SilverAzide »

Interesting. This is not something that I have ever seen on any of my machines, nor have any other users reported similar behavior. This might be something unique to you, unfortunately.

I have seen rare cases where Rainmeter does not detect a network adapter change, but in most cases this was caused by an issue in Windows itself.

When you switch adapters, does the network adapter name change? You can try the Network Meter skin (not the Wireless Meter), the active adapter is shown in dark orange, on the second line below the Ping time. You should see it change from your ethernet adapter to your wifi adapter, and vice versa, without needing to refresh the skin or Rainmeter.
Gadgets Wiki GitHub More Gadgets...
neo.nemek
Posts: 36
Joined: February 11th, 2023, 7:52 am

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by neo.nemek »

Yes, the names of the interfaces appear correct and the change is also detected correctly in all the Skins, all the data is correct except the QUALITY Signal data and the SSID, these data despite being connected to my Wi-Fi and giving me a dynamic internal IP , they are not displayed correctly, they are only displayed if I update the Skins manually.
You do not have the required permissions to view the files attached to this post.
User avatar
SilverAzide
Rainmeter Sage
Posts: 2605
Joined: March 23rd, 2015, 5:26 pm

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by SilverAzide »

neo.nemek wrote: February 21st, 2023, 10:47 pm Yes, the names of the interfaces appear correct and the change is also detected correctly in all the Skins, all the data is correct except the QUALITY Signal data and the SSID, these data despite being connected to my Wi-Fi and giving me a dynamic internal IP , they are not displayed correctly, they are only displayed if I update the Skins manually.
Well, this is certainly strange. Not sure what to tell you. These values should be available always (even if the adapter is not the "active" one). The fact that refreshing all skins fixes it might point to a bug in Rainmeter itself. But the fact that this isn't happening to everyone is going to make finding a fix difficult.

However, in any case, the good news is that you can use the fact that the adapter name (or type, or etc.) is changing to act like a "trigger". In other words, you can add code to your skin so that if your active adapter changes to your wireless adapter, you can refresh your skin. It's unfortunate to have to do that, but I don't see another way at this point. (It's not a simple fix by the way, you have to be careful not to get into an infinite loop, which will hang or crash Rainmeter.)
Gadgets Wiki GitHub More Gadgets...
neo.nemek
Posts: 36
Joined: February 11th, 2023, 7:52 am

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by neo.nemek »

SilverAzide wrote: February 22nd, 2023, 3:53 am
However, in any case, the good news is that you can use the fact that the adapter name (or type, or etc.) is changing to act like a "trigger". In other words, you can add code to your skin so that if your active adapter changes to your wireless adapter, you can refresh your skin. It's unfortunate to have to do that, but I don't see another way at this point. (It's not a simple fix by the way, you have to be careful not to get into an infinite loop, which will hang or crash Rainmeter.)
Great SilverAzid I just updated the Wi-Fi driver with an official Linksys driver and it doesn't solve the problem either, my OS is Windows 11, the latest version available and the Rainmeter is also the latest version available.

At this point and as I said in previous posts, I must do a routine that after the Wi-Fi connection and by comparing some data, the Network Monitor Skin.ini refreshes itself without falling into a loop.
The problem due to my little experience with the code is that everything I have tried has not worked or has fallen into a loop, I don't know how to deal with or design a code that only refreshes once when Wi-Fi is active and connected to my Wi-Fi network completely.

Can you help me to design this code?
User avatar
SilverAzide
Rainmeter Sage
Posts: 2605
Joined: March 23rd, 2015, 5:26 pm

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by SilverAzide »

neo.nemek wrote: February 22nd, 2023, 8:51 am Great SilverAzid I just updated the Wi-Fi driver with an official Linksys driver and it doesn't solve the problem either, my OS is Windows 11, the latest version available and the Rainmeter is also the latest version available.

At this point and as I said in previous posts, I must do a routine that after the Wi-Fi connection and by comparing some data, the Network Monitor Skin.ini refreshes itself without falling into a loop.
The problem due to my little experience with the code is that everything I have tried has not worked or has fallen into a loop, I don't know how to deal with or design a code that only refreshes once when Wi-Fi is active and connected to my Wi-Fi network completely.

Can you help me to design this code?
Let me think on this a bit. It is a little tricky to do properly without causing a loop or unwanted refreshes.
Gadgets Wiki GitHub More Gadgets...
User avatar
SilverAzide
Rainmeter Sage
Posts: 2605
Joined: March 23rd, 2015, 5:26 pm

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by SilverAzide »

neo.nemek wrote: February 22nd, 2023, 8:51 am Can you help me to design this code?
Try the following. Edit the Gadgets Network Meter skin (not the "Pro" skin) and at the top of the file, locate the variable WiFiInterfaceID. Change the value of this variable to 1, like so: WiFiInterfaceID=1. Refresh the skin, then try activating and switching to your Wi-Fi network adapter to see if the signal quality shows up. If it does not try setting the value to 2, and repeat. I'm not sure this will change anything, but it is worth a try. If it doesn't work, set the variable back to 0.

I think part of the issue might be the fact that your Wi-Fi adapter is a USB device. Activating this device might be causing a problem with Rainmeter's WiFiStatus measure when network adapters change.
Gadgets Wiki GitHub More Gadgets...
neo.nemek
Posts: 36
Joined: February 11th, 2023, 7:52 am

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by neo.nemek »

SilverAzide wrote: February 23rd, 2023, 12:01 am Try the following. Edit the Gadgets Network Meter skin (not the "Pro" skin) and at the top of the file, locate the variable WiFiInterfaceID. Change the value of this variable to 1, like so: WiFiInterfaceID=1. Refresh the skin, then try activating and switching to your Wi-Fi network adapter to see if the signal quality shows up. If it does not try setting the value to 2, and repeat. I'm not sure this will change anything, but it is worth a try. If it doesn't work, set the variable back to 0.

I think part of the issue might be the fact that your Wi-Fi adapter is a USB device. Activating this device might be causing a problem with Rainmeter's WiFiStatus measure when network adapters change.
No, it doesn't work even setting WiFiInterfaceID=1 or 2. I've done what you suggest without forgetting to refresh the Skin WirelessMeter no PRO, but the SSID still doesn't appear unless I update the Skin during the WIFI network connection.
All the other data is shown correct, it measures the Upload and Download, it gives me the IP, and all the other data but the SSID is not and it always appears as disconnected, we continue investigating.... :welcome: :???:
User avatar
SilverAzide
Rainmeter Sage
Posts: 2605
Joined: March 23rd, 2015, 5:26 pm

Re: IfCondition Show/Hide MeterImage or MeterGroup

Post by SilverAzide »

Hm. Not sure what to tell you. For some strange reason, the WiFiStatus measure is not seeing your network adapter change, whereas all the other network measures do see the change. Without being able to duplicate your setup, I'm out of ideas. I'd need to see the debug logs and measure values for myself to get any further on this, as I can switch adapters on/off, wifi/ethernet, etc. and all works perfectly.

:confused:
Gadgets Wiki GitHub More Gadgets...