Win XBMC Startup in folder
#1
Is there a way that when my XBMC starts it automaticly goes to my video->folder->movies(custom folder)?

And if so, how? ima nub in code's so i hope thats not the way.
Reply
#2
Assuming that folder can be accessed within XBMC, you can do the following:
  1. In XBMC: Videos > Files
  2. Drill down to the page that shows this folder, highlight the folder name and open the context menu ("c" on keyboard or right mouse button)
  3. Select "Add to favourites"
  4. Exit XBMC and locate the favourites.xml file in your userdata (wiki) directory
  5. Open the file with a text editor and locate the statement for your folder. It should look something like this:
    Code:
    <favourite name="your-folder-name">ActivateWindow(...)</favourite>
    (where "..." represents the actual text that is in this statement)
  6. Make a note of the ActivateWindow(...) text from the statement
  7. See this post to create an autoexec.py file. However, in your script, use the ActivateWindow(...) text you copied from favourites.xml instead of ActivateWindow(Videos,Files) as shown in the example. So the resulting script statement will look like this:
    Code:
    xbmc.executebuiltin("ActivateWindow(...)")
  8. Launch XBMC and it should open up to your folder.

EDIT: Corrected misspelling in Step 7. Should be: autoexec.py
Reply
#3
Wow thnx man. I could never figure it out myself.
Gonna try as soon i get home!

Thnx somuch
Reply
#4
Sorry to revive an old thread but this is achingly close to what I'm trying to do. However the script takes me to a blank list/window. Accessing through Favorites jumps to the right place but the same ActivateWindow command in a python script doesn't.

Favorites.xml:
Code:
<favourite name="Movies">ActivateWindow(10025,&quot;smb://MEDIA1/media1/Movies/&quot;)</favourite>

python script:
Code:
xbmc.executebuiltin( "ActivateWindow(10025,&quot;smb://MEDIA1/media1/Movies/&quot;)" )

Frodo 12.2

What am I doing wrong?
Reply
#5
Probably because the SMB share isn't yet available to XBMC at the point in time when the autoexec.py is executed. On the other hand, by the time you get to launching the favourite, the share is now available. You may need to add a delay/check in your script to allow the share to become available before you run your xbmc.executebuiltin statement.
Reply
#6
I just played around with this for a bit. Try changing your statement to:
Code:
xbmc.executebuiltin( "ActivateWindow(10025,smb://MEDIA1/media1/Movies/)" )
and see if this works.
Reply
#7
@artafael

That works. Thank you!
Reply

Logout Mark Read Team Forum Stats Members Help
XBMC Startup in folder0