Kodi Community Forum

Full Version: How to run a .bat file on the exit xbmc button in a skin?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi all

I was wanting to know how to run a .bat file by using the exit button in the menu ? i have had a look at the DialogButtonMenu.xml and found this

<control type="button" id="1">
<description>Exit XBMC</description>
<label>[UPPERCASE]$LOCALIZE[13012][/UPPERCASE]</label>
<include>Objects_ContextMenuButton</include>
<onclick>XBMC.Quit()</onclick>
</control>

I was wanting to know how to run a .bat file instead of the exit command is there a way as i tried this

<control type="button" id="1">
<description>Exit XBMC</description>
<label>[UPPERCASE]$LOCALIZE[13012][/UPPERCASE]</label>
<include>Objects_ContextMenuButton</include>
<onclick.(c:/exit.bat)</onclick>
</control>

and nothing happens can anyone tell me how to

thanks

Perhaps this?

Code:
<onclick>XBMC.System.Exec(c:/exit.bat)</onclick>
thanks that worked, i was woundering how you use the shutdown screen version instead of the context menu exit as i can not find the shutdown option in DialogButtonMenu.xml what would the main shutdown main menu xml file be called

cheers
If you're trying to assign a key to launch the XBMC shutdown menu, try:
Code:
<some-key>ActivateWindow(shutdownmenu)</some-key>
Hi

No it's the main xbmc window where you have a scroll bar with movies, video, weather and then u have shutdown. I want to change how the shutdown option works as I don't want it to shutdown but to run my bat file but the XML I am in must not control that part and must be in another XML file. I think

Cheers
I'm assuming you've already read this thread since you'd mentioned looking in DialogButtonMenu.xml? Are you using the default Confluence skin or something else?
Hi there

I am using Aeon Nox on xbmc 10.1, no i did not read that post. I just altered the exit line but wanted tobe able to run the batch file on the main screens shutdown option and not the context menu shutdown.

cheers
You may want to ask over in the Aeon Nox subforum since this is probably a skin-specific question. The link I gave you in my previous post was for changing the Shutdown menu for the Confluence skin.
cheers will do