ReferenceError: Error #1065: Variable is not defined.

ReferenceError: Error #1065: Variable item 1 is not defined.

The problem is that a variable is not defined. But it does not tell you where. You have to follow the method stack or do a search for the variable since no line number is given. In my case there were no curly braces around the dataprovider string array in the DataGrid. Using a string array without curly braces actually works in a List component but when using a DataGrid an error is thrown. See below.

// incorrect in List (but works)
	
// correct
	

// incorrect in DataGrid (does not work)
	
// correct
	

Another case where you must define the id in curly braces:


	
		
			
			
			
			
		
	
	
	
		
		
	

CHANGE the dataProvider to this and it will work:

	

Please leave a comment if this has helped you or not. Also check out the error search application.

ReferenceError: Error #1065: Variable is not defined.

4 thoughts on “ReferenceError: Error #1065: Variable is not defined.

  1. Kusha waghmare says:

    i got this error: ReferenceError: Error #1065: Variable SomeclassName is not defined.
    this basically occurs when you won’t append public before the class.

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s