Question

JSON5 invalid character error.

 Not sure, why I get that error.

Please, can someone help me in understanding how to resolve it?

Like 0

Like

4 comments
Best reply

Jahnavi,

 

Hi,

 

Adding attributes in the way it's done in the old UI to the schema of the Freedom UI page will not work and opening such a page in the wizard can result in the error with JSON parsing. Please remove them from the Freedom UI schema since they break the designer functionality.

I get this error when I try to open the form page designer

I found that it is because of below declaration.

       Please, can anyone explain what is wrong with this? Or how to use VIRTULA_COLUMNS?

          

		"UsrMaxVal": {},
					"responseCollectionGamesConducted": {
                				"dataValueType": Terrasoft.DataValueType.INTEGER,
                				"type": Terrasoft.ViewModelColumnType.VIRTUAL_COLUMN
            		},
					"regionalIdVal": {
                				"dataValueType": Terrasoft.DataValueType.GUID,
                				"type": Terrasoft.ViewModelColumnType.VIRTUAL_COLUMN
            		},	

 

Hello Jahnavi,

I can tell you from the given information that parsing the JSON gives an error, but we don't see the JSON itself. You should look for an extra character "T" in your JSON string. The error is in the code of the schema most probably and that is why it's impossible to open the app page. I would recommend you to catch the body with debugging.

Virtual columns example based on your code (didn't get what is "UsrMaxVal": {}, means):

 define("PageName", [], function() {
		return {
			entitySchemaName: "SchemaName",
			attributes: {
					"responseCollectionGamesConducted": {
                				"dataValueType": Terrasoft.DataValueType.INTEGER,
                				"type": Terrasoft.ViewModelColumnType.VIRTUAL_COLUMN
            		},
					"regionalIdVal": {
                				"dataValueType": Terrasoft.DataValueType.GUID,
                				"type": Terrasoft.ViewModelColumnType.VIRTUAL_COLUMN
            		},
			},
			messages: {},
			methods: {},
			details: /**SCHEMA_DETAILS*/ {} /**SCHEMA_DETAILS*/ ,
			diff: /**SCHEMA_DIFF*/ [
			] /**SCHEMA_DIFF*/
		};
	});

 

Jahnavi,

 

Hi,

 

Adding attributes in the way it's done in the old UI to the schema of the Freedom UI page will not work and opening such a page in the wizard can result in the error with JSON parsing. Please remove them from the Freedom UI schema since they break the designer functionality.

Show all comments