Hi,
Trying to write a script to modify some controls in a windows defined in the skin (ultimately some sliders, in the manner of this post)
Have a window defined like this:
<window id="6660">
<onload>runscript(special://skin/extras/scripts/timeshiftprogress.py)</onload>
<controls>
<control type="label" id="6661">
<top>134</top>
<left>700</left>
<width>50%</width>
<height>60</height>
<label>XXXX</label>
<shadowcolor>black</shadowcolor>
</control>
......
The script contains:
import xbmc
import xbmcgui
w = xbmcgui.WindowDialog(6660)
c = w.getControl(6661)
c.setLabel('hello')
The window comes up and shows the label, the script runs, but Kodi reports
EXCEPTION: Non-Existent Control 6661 in the log. Any existing control id in the XML behaves the same.
Should I be able to do this? I have read hints elsewhere that only script-created controls can be got with getControl; is this the case? (I will try it, anyway)
Curiously, if I try to get the window ID with xbmcgui.Window(6660) it reports a nonexistent window. Not sure if this is a clue (the window actually is a dialog, afaik – it is DialogSeekBar.xml of estuary)