Hi,
I'm working on a sports app with teams. Depending on the date, different team
matchups will be displayed. However, before the 11th we just want to display
the matchup for the 11th.
I have the following code, but I'm getting a compile-time error:
"Target of assignment must be a reference value."
Here's the code.
var now:Date = new Date();
var currentDate:String = now.getDate().toString()
//if the current date is before the 11th, set it to the 11th
if((Number(currentDate)) < 11)
{
Number(currentDate) = 11; //error is here
}
else
...
I realize I'm assigning a value to a value, and that's the problem. I'm just
not sure how to fix it.
Thanks.