Kodi Community Forum

Full Version: runaddon onclick does not work
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
My English is very bad to forgive for expressing myself badly

I am setting the confluence widget from xml with this code
<content sortby="lastused" sortorder="descending" target="addons" type="xml" limit="20">plugin://plugin.audio.radio_de</content>

but when loading the widget with
does nothing
I tested with this code

if it worked to reproduce but not to open the addon some idea of ​​what is my error
I'm not 100% sure what you are trying to do, are you trying to open Radio stations from the Widget? Using Auto Widgets may be helpful to you https://forum.kodi.tv/showthread.php?tid=352934
If i try to open radio from a widget written in xml
<control type="group">
                <visible>!Skin.HasSetting(HomepageHideWidgetRadios) + Container(9000).Hasfocus(108) </visible>
                <animation effect="fade" start="0" end="100" time="300" delay="350">Visible</animation>
                <control type="group">
                    <control type="label">
                        <description>Title label</description>
                    <control type="panel" id="8004">
                        <include content="radioNormal" />                                
does $INFO[Container(ID).ListItem.Property(Addon.ID)] return anything if you use it in a label control?

also, check if there's anything in the Debug Log that might provide a clue.
Returns nothing, Debug Log, or anything, does nothing when pressed
ok, well there's you answer :-)
you're trying to use a listitem property that doesn't exist.
So how could I launch the addon from the widget using RunAddon if there is some way
well, you could hardcode the addon id.
..but what's the reason you want to override <onclick> ?
I don't want to override the <onclick>.
I think I explained badly I would like to launch the addon from onclick
adding an <onclick> tag to the container like you are doing:
will override the default onclick behaviour that has been set for each listitem.

also see: https://kodi.wiki/view/Dynamic_List_Cont...ick_action
So how should I put why I think that <onclick> is not if I put this code if it works
well hardcoding the addon id will work

another thing that *might* work is:
<onclick>ActivateWindow(music, $INFO[Container(ID).ListItem.Path])</onclick>
Thank you very much it is already solved