Highlighted

About parse error of coldfusion2016

New Here ,
Jul 12, 2017

Copy link to clipboard

Copied

Currently I am migrating from coldfusion 7 to coldfusion 2016.

When analyzing with the code analyzer of coldfusion2016, Parse Erro comes out in this line

<cfoutput>#writeLog("DS001", "#This.Name#", "SDC601", ArrayNew(1))#</cfoutput>

I will be saved if you tell me how to deal with it.

Thank you

Views

229

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

About parse error of coldfusion2016

New Here ,
Jul 12, 2017

Copy link to clipboard

Copied

Currently I am migrating from coldfusion 7 to coldfusion 2016.

When analyzing with the code analyzer of coldfusion2016, Parse Erro comes out in this line

<cfoutput>#writeLog("DS001", "#This.Name#", "SDC601", ArrayNew(1))#</cfoutput>

I will be saved if you tell me how to deal with it.

Thank you

Views

230

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jul 12, 2017 0
Contributor ,
Jul 12, 2017

Copy link to clipboard

Copied

Read the documentation on WriteLog here:

https://helpx.adobe.com/coldfusion/cfml-reference/coldfusion-functions/functions-t-z/writelog.html

Seems like you need to structure your writeLog statement a little differently?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 12, 2017 0
BKBK LATEST
Adobe Community Professional ,
Jul 12, 2017

Copy link to clipboard

Copied

沙耶石67903450  wrote

<cfoutput>#writeLog("DS001", "#This.Name#", "SDC601", ArrayNew(1))#</cfoutput>

The function writeLog takes 5 arguments. They are: type, text, application, file and log. (File and log may be interchangeable)

All of them have either string or boolean value. Therefore the value ArrayNew(1) is out of place. It is also unclear what the value of each of your 4 arguments is. To solve the problem, include the argument name in the function call, for example:

writeLog(type="error", file="DS001", application="yes", text="#This.Name#");

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 12, 2017 0