EL function error  [SOLVED]

Questions about MultiCharts and user contributed studies.
plaforte
Posts: 75
Joined: 16 Aug 2012
Has thanked: 17 times
Been thanked: 2 times

EL function error

Postby plaforte » 16 Aug 2012

Hello, I copied pasted an EL indicator and function to a new PL indicator and a new function. It works in TS but I get an error message when compiling the function and so in the indicator as well.

the error message is "assignment is allowed only for variables or array elements" error line 29, which is the last line of my code below it also says "causal study: Function"

Here is my code

Code: Select all

[LegacyColorValue = true] ;

Input: _Color( NumericSimple),
_Thickness( NumericSimple),
_TimeStart( NumericSimple),
_DateStart( NumericSimple),
_TimeEnd( NumericSimple),
_DateEnd( NumericSimple),
_PriceHi( NumericSimple),
_PriceLo( NumericSimple);

Vars: Top( 0), Bottom( 0), Left( 0 ), Right( 0 );

{Draw bottom line}
Bottom =TL_New( _DateStart, _Timestart, _PriceLo,_DateEnd, _TimeEnd, _PriceLo );
TL_SetColor( Bottom, _Color );
Value1 = TL_SetSize( Bottom, 0 ); // originally it was Value1 = TL_SetSize( Bottom, _Thickness );

{Draw top line}
Top =TL_New( _DateStart, _Timestart, _PriceHi,_DateEnd, _TimeEnd, _PriceHi );
TL_SetColor( Top, _Color );
Value1 = TL_SetSize( Top, 0 );

_DrawBox3 = 0;

Thank you for any help

User avatar
TJ
Posts: 7743
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: EL function error

Postby TJ » 16 Aug 2012

what is the name of the function you are trying to create?

plaforte
Posts: 75
Joined: 16 Aug 2012
Has thanked: 17 times
Been thanked: 2 times

Re: EL function error  [SOLVED]

Postby plaforte » 16 Aug 2012

Thank you TJ. GOT IT

my function name was missing the first character _

Best regards


Return to “MultiCharts”