1 Reply Latest reply on Aug 1, 2006 5:46 AM by Newsgroup_User

    Please Help!!

    sarah louise water


      Can anyone please help.
      I am developing a maths project. All I need to do is change a text member's text property for each lesson. I am using this particular text member to store a database field's text (the lesson title) in order to save a record. It is working the first time I use the function, but on the second the text member remains blank, thus causing an error in the database record.

      Or is there a behaviour that changes a text member's text property.
      Many Many Thanks

      Here is my code for the lessons-


        • 1. Re: Please Help!!
          Level 7
          There is nothing wrong with the code that you posted. You could do this
          more simply like this:

          member("CurrentLesson").text = member("title").text

          You don't really need to go through the variable. Cast members and their
          content are global to the movie. So you can get the text of any text
          member at any place in the movie.

          There are three things that I can think of that may cause your current
          code to not work. The first is that the variable that you are using,
          ThisLesson, for instance is falling out of scope from the first time
          that you use to the second time. If you are declaring the variable
          inside a function, then that variable will only have a value in that
          function. If this is a property variable, then it will only hold that
          value in one behavior window. The variable will have to be global in
          order to have it's value available in more than one location in the
          movie.

          The second possible problem is that the variable is being reset to a new
          value at some point from where you are setting it where you are trying
          to use it.

          The third possible problem is that you have more than one member named
          "title" or "CurrentLesson".

          --
          Rob
          _______
          Rob Dillon
          Adobe Community Expert
          http://www.ddg-designs.com
          412-243-9119

          http://www.macromedia.com/software/trial/