Solved

unexpected constant Error

Posted on 2004-08-11
5
741 Views
Last Modified: 2013-12-20
Hi

I wonder if there is a workaround for this error " Error Occurred While Processing Request  
unexpected constant #127 -1 " The number 127 varies depending on how many lines of JavaScript function I insert.

I'm adding a dynamic menu function that contains 3720 lines. Every time I add the function to the coldfusion template, it generates this error. Even after I remove the function from the template I keep getting the error and the template becomes useless.. Weird uhh? but it's happening to me.

 
Does coldfusion has a limit of lines to be included in a template?
0
Comment
Question by:gaby22
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 15

Accepted Solution

by:
danrosenthal earned 500 total points
ID: 11777262
Found this on Macromedia's website of known issues:

Large ColdFusion pages
===============
ColdFusion pages that are larger than 500 KB can cause the following compilation error:
java.lang.IllegalStateException: unexpected constant at coldfusion.compiler.ClassReader.readCpool(ClassReader.java:153)  

Link: http://www.macromedia.com/support/coldfusion/releasenotes/mx/knownissues_mx_j2ee_p2.html
0
 
LVL 9

Expert Comment

by:Jerry_Pang
ID: 11780196
this happened to me before.

I think i use cf_include statements to workaround this problem.  
This usually happens to me if the files gets too big.
I split the file into multiple small files and 1 file to cf_include them all.


give it a try

regards,
jerry
0
 

Author Comment

by:gaby22
ID: 11793769
I tried using includes without any luck. I also tried using <script language="javascript" src="file.js> to avoid having the page with long scripts but doesn't work either.
0
 
LVL 2

Expert Comment

by:russmichaels
ID: 11800831
Are you sure that there is not something else on the page conflicting with this javascript. Do you have any other scripts onthe page.
0
 
LVL 9

Expert Comment

by:Jerry_Pang
ID: 11817781
hmm.. i thinking there might be something on the page.
perhaps a comment that was not closed
<!--- with out --->
or <!--- <!--- --->

or something like that. probably a syntax error or an unclosed tag.
or a # somewhere without the pair.


0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Article by: kevp75
Hey folks, 'bout time for me to come around with a little tip. Thanks to IIS 7.5 Extensions and Microsoft (well... really Windows 8, and IIS 8 I guess...), we can now prime our Application Pools, when IIS starts. Now, though it would be nice t…
Introduction This article explores the design of a cache system that can improve the performance of a web site or web application.  The assumption is that the web site has many more “read” operations than “write” operations (this is commonly the ca…
The purpose of this video is to demonstrate how to exclude a particular blog category from the main blog page. This is can be used when a category already has its own tab, or you simply want certain types of posts not to show up on the main blog. …
The purpose of this video is to demonstrate how to add AdSense Ads to a WordPress Website, and how to set up WordPress to automatically place Ads in Sidebars. This will be demonstrated using a Windows 8 PC. Log into your AdSense account. : Cli…

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question