Reference Error for property of Javascript Object
Posted
by Jeremy Petzold
on Stack Overflow
See other posts from Stack Overflow
or by Jeremy Petzold
Published on 2010-04-18T12:55:17Z
Indexed on
2010/04/18
13:03 UTC
Read the original article
Hit count: 350
JavaScript
|google-apps-script
I have built an object in Javascript on the Google Apps Script engine and every time I run my script I get a reference error saying uName is not defined.
Here is the relivant code:
function DataSet()
{
this.uName = "";
this.dFeild = "";
this.qUrl = "http://api.bfbcs.com/api/pc?players="+uName+"&fields="+dFeilds;
this.data = "";
this.dQuery = dQuery;
this.execQuery = execQuery;
According to all sources I have found, I should not need to use the keyword var, and when I do include that, it throws other errors.
What could be going on?
Thanks
© Stack Overflow or respective owner