General Logic for Playlist help

I’m really stumped.
I have a movie that has two text fields on screen, A next button, a Previous button and a dynamically generated playlist. Everything is being populated by an XML document.

The next/previous buttons cycle through the XML document and populate the text fields accordingly. The buttons in the playlist populate the textfields when clicked. No problems there.

The problem is when I select an item from the playlist, then try to use the NEXT/PREVIOUS buttons.
The function that initially populates the text checks for a variable that sets the index position to 0. So whenever I select an item from the playlist, then click on the NEXT button it is looking for the last position set by the NEXT/PREVIOUS buttons. Not the position set by the playlist item.

I’m not sure exactly sure what needs to occur once a playlist item is selected, so that playlist item is also triggered by the NEXT & PREVIOUS buttons. Here is an example of what I am trying to achieve :
If you click the next&previous buttons it cycles through on the playlist etc. etc. ( I love how this example kicks out 90 million errors too…)

Sorry if this sounds confusing. I’m like a caveman trying to fly a spaceship when it comes to programming. Any help would be greatly appreciated.