umm don't think I follow? Create a shortcut to the bat file and place it on your desktop? Your problem is unique so really can't understand why this is happening only in your case :/
Anyway, got to get back to work, will get back to this later!
I just put the code in def Start(): so that I could test without the worry of any of the other logic being the cause of the unlock not working.
The standard stuff was not running in def.start(). Only os.startfile(path) was. I just tried all sorts of ways to open the file when the channel loaded. This appears to be the only way I was able to make it work. I have a feeling it has something to do with window and quotes around paths with spaces.
No success with subprocess.call, but if you had time I suspect you could run the sqlite3 query right from there using it. I couldn't get it to work though.
Also might note that I still can't see unlock in plexweb for some reason. Works on the phone though and that's what matters more.
Hmm, let me know how that goes! it was always meant to/was working with os.startfile(path) for all other Windows folk ;)
Have you installed python on your windows? is there a library conflict maybe?! how come it's running when you put everything in def.start() food for thought!
Sent from my iPhone using Tapatalk
Btw, my plugin came with os.system() not os.startfile(). I had to change it to get it to work.
I ended up using the following in the end:
BASEPATHLOCK = Core.storage.join_path(Core.app_support_path, Core.config.bundles_dir_name)+"\Lock.bundle\Contents\Resources\lock_support\lock.bat"
BASEPATHUNLOCK = Core.storage.join_path(Core.app_support_path, Core.config.bundles_dir_name)+"\Lock.bundle\Contents\Resources\lock_support\unlock.bat"
Although most would likely work. Is there one in particular you’d like to try?
No worries, it happens. Just glad I could help and learned a little Python along the way.
Ohh and remember to remove the “open”, when using os.startfile(path) 
im having an issue where it says lock.. I click it it says it was successful locking. I kept locking and restarting the client because it wouldn't actually lock. I am on plex web. Now it made the section disappear
edit... did not realize it is supposed to hide the whole section.. Just on plex/web when its locked it wont show the unlock icon only on my ipad.
@cmtahm are you referring to the lack of an unlock icon on plexweb like I was?
@cmtahm are you referring to the lack of an unlock icon on plexweb like I was?
yes. also i would like to request being able to lock more than one section.
OMG: I misunderstood that post. I thought you had to click on unlock first before entering in the search bar. :(
Is there are way to add a line of text in the channel that reads: "To unlock please enter your password in the search input above." ?