Click here to Skip to main content
15,889,281 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
C#
private var currentIndex:int = 0;

private function txtTemplate_change():void
{
   arrChanges.push(txtTemplate.htmlText);
   currentDataIndex = arrChanges.length - 1;
}

/** Undo changes **/
private function btnUndo_click():void
{
   if(currentDataIndex >= -1)
   {
      txtTemplate.htmlText = arrChanges[currentDataIndex];
      currentDataIndex--;
   }
}

/** Redo Changes **/
private function btnRedo_click():void
{
   if(currentDataIndex+1 < arrChanges.length)
      {
         currentDataIndex++;
         txtTemplate.htmlText = arrChanges[currentDataIndex];
      }
}

i pasted these code in my app i am getting so many errors please provide detailed code for me iam new to this flex
Posted
Comments
Maciej Los 7-Mar-14 12:37pm    
It looks like code-dump! You're not an author of this part of code. Do you expect from us that we can help you?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900