Posts: 48
Joined: Oct 2008
Reputation:
1
effe
Junior Member
Posts: 48
2015-08-28, 20:36
(This post was last modified: 2015-08-28, 20:38 by effe.)
Nope. Doesn't works. By the way where did you find that syntax?
Just for a quick recap this is what I tried for now:
-On my xml:
<label>$INFO[skin.String(tempo)]</label>
Works if I use setstring on py.
<label>$INFO[skin.SetString(tempo,31)]</label>
Works if I force a skin reload on py when I change the value using sed.
- On my py:
tempo2 = '31'
with or without quotes, it's the same. It's just a local variable before using the true one on my txt generated by python after looking on my database.
xbmc.executebuiltin("Skin.SetString(tempo,tempo2)")
doesn't update even forcing a skin reload and use the value in cache (if present).
xbmc.executebuiltin("Skin.SetString(tempo, {0}".format(tempo2))
doesn't update even forcing a skin reload and use the value in cache (if present).
xbmc.executebuiltin("ReloadSkin()")
xbmc.executebuiltin("Skin.SetString(tempo,31)")
works.
Posts: 1,109
Joined: Feb 2011
Reputation:
39
Looks like you're missing a bracket after the }. Take a look at my example again. But if this was wrong, you should be getting a script error...
Posts: 1,109
Joined: Feb 2011
Reputation:
39
Actually, thinking about it, it wouldn't report an error because you're sending a command as a string. Your previous code was still a string, so no code error, it's just that Kodi didn't know how to handle it.
Glad it's working now!
Posts: 1,109
Joined: Feb 2011
Reputation:
39
Never used psycopg2. No idea why you are getting mixed results. Try putting some debugging in your code and see what the string value is.