Dyamic News // Flash

Out of context: Reply #4

  • Started
  • Last post
  • 4 Responses
  • nameless0

    hey robo, i just made one of those last week. asp and everything.

    I had already written the asp news poster to deliver HTML content, so all i had to do was implement the flash news ticker.

    here is how i went about it...

    make a movie clip which contains a dynamic text area named currentNews on the movieClip have a onLoad event which contains a LoadVariables which will load your variables script. I started with a text file called news.txt that looked like this...

    newsTitle1=foo&newsTitle2=bar

    then on the movie clip make an event as so...

    onClipEvent (data) {
    newsTitle1 = news1;
    newsLink1 = link1;
    newsTitle2 = news2;
    currentNews = newsTitle1;
    currentLink = newsLink1;
    _parent.play();
    }

    what the data event does is waits for all the data to be loaded before it does anything else, then sents the news title for you dynamic field and then plays the movie. you can have the text fade in and such.

    next step is to make a timer that counts how long the text has been up and if it has been up for a certain amount of time, set the current news to = newsTitle2.

    the link to the news comes in when you put a clear button over the dynamic text inside the movie, and tell the URL to be an expression, your variable currentLink

    get the idea?

    one problem with this is that it doesnt like dynamic variables. i am trying to solve this with no luck, so i might have to go to XML.

    the other side of this app is an ASP script which uses a SQL statment to pull data out of the database i made for the original news app. i replaced my static text testing file with that script. when i had my flash functionality done.

    sorry i was so vauge, just trying to set you in the right direction.

View thread