Answered
CFFunction
This is a weird error.
I have a template that includes a bunch of include files. Two of them are custom functions:
includes "ScientificFormat.cfm" and "SetMOA.cfm".
The ScientificFormat function/include works fine until I try to call SetMOA.cfm. At that point, I get the error:
Routines cannot be declared more than once.
The routine "scientificFormat" has been declared twice in different templates.
I know that ScientificFormat is not called anywhere in the page that use the SetMOA function (TMOA.cfm). I comment out the
include files in TMOA.cfm and the code runs fine. What it seems to boil down to is that I can make a call to SetMOA on
TMOA.cfm, but not in any files included in TMOA.cfm.
Am I calling the function right, or doing somethng wrong. I'm trying to pass one parameter to the function:
TMOA.CFM - Works Fine
<CFSET SetMOA(31)/>
TMOA.CFM
<cflinclude template = "esters.cfm">
Esters.cfm - doesn't work:
<CFSET SetMOA(32)/>
I have a template that includes a bunch of include files. Two of them are custom functions:
includes "ScientificFormat.cfm" and "SetMOA.cfm".
The ScientificFormat function/include works fine until I try to call SetMOA.cfm. At that point, I get the error:
Routines cannot be declared more than once.
The routine "scientificFormat" has been declared twice in different templates.
I know that ScientificFormat is not called anywhere in the page that use the SetMOA function (TMOA.cfm). I comment out the
include files in TMOA.cfm and the code runs fine. What it seems to boil down to is that I can make a call to SetMOA on
TMOA.cfm, but not in any files included in TMOA.cfm.
Am I calling the function right, or doing somethng wrong. I'm trying to pass one parameter to the function:
TMOA.CFM - Works Fine
<CFSET SetMOA(31)/>
TMOA.CFM
<cflinclude template = "esters.cfm">
Esters.cfm - doesn't work:
<CFSET SetMOA(32)/>
