Skip navigation
Rick.Blacker
Currently Being Moderated

Odd error on the simplest app.

Sep 23, 2013 8:50 PM

All, I was going to do a little proof of concept app. I created a new air project. opened up the MXML file, created an fx:script block, wanted to create a variable and use it. However, I'm getting the following error. 

 

DescriptionResourcePathLocationType
1120: Access of undefined property blah.App1.mxml/App1/srcline 12Flex Problem

 

Here is my MXML.

 

<?xml version="1.0" encoding="utf-8"?>

<s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009"

                                                     xmlns:s="library://ns.adobe.com/flex/spark"

                                                     xmlns:mx="library://ns.adobe.com/flex/mx">

 

          <fx:Declarations>

  </fx:Declarations>

 

          <fx:Script>

                    <![CDATA[

 

      private var blah:String;

      blah = new String( );

      blah = "hi there";

                    ]]>

          </fx:Script>

</s:WindowedApplication>

 

 

I'm at a loss as to why I'd be getting an Access of undefined propery blah... For grins, I did the EXACT same thing on another computer and it works just fine. There must be something about this one computer that I'm working on that is not configured correcty.  Thoughts???

 
Replies
  • Currently Being Moderated
    Sep 23, 2013 10:12 PM   in reply to Rick.Blacker

    It looks like you have code that isn't in a function or part of a variable declaration.  That's 'legal' in AS, but MXML doesn't like it.

     

    -Alex

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points