Preface: I wrote a script that runs when it detects my usb wifi device is attached. When inserted, it change's netload's watched interface from wlan0 to wlan1, and vice-versa when removed.
In order for netload to use the updated config file, I have to pkill 'xfce4-netload-plugin' and the applet automatically respawns and parses it correctly. This works great, but my problem is, when I insert/remove too many times (resulting in lots of respawns), a warning message comes up asking me if I really want to reload the applet again.
My question is, is there a graceful way to reload panel applets so that won't trigger this message?
The following command will cause the entire panel to restart itself:
dbus-send --print-reply --dest=org.xfce.Panel /org/xfce/Panel org.xfce.Panel.Terminate boolean:true
This might be a little drastic, but would achieve your intended goals.
Thanks Jules! This method actually has actually helped me a-lot on another script I am making.