setCursorLabelName()

ICE Data Services -

setCursorLabelName()
Previous  Top  Next


setCursorLabelName( label [, index] )

This function sets the name of a value (to be displayed in the eSignal cursor window) that is returned by an eSignal script. A script can return 1 value or return multiple values. You would use setCursorLabelName() to set a name for each value that your script returns.

Parameters

label
text string to be displayed in cursor window
index
optional. the index position from the return array of returned values from main()


Usage

function preMain() {

   setPriceStudy(
true);
   setStudyTitle(
"Example Script");

   
//this script returns 3 values to be plotted on the chart.
   
//use setCursorLabelName() to set a name for each return
   
//value

   setCursorLabelName(
"EMA"0);
   setCursorLabelName(
"SMA"1 );
   setCursorLabelName(
"WMA"2 );

   setDefaultBarFgColor( Color.blue, 
0 );
   setDefaultBarFgColor( Color.red, 
1 );
   setDefaultBarFgColor( Color.green, 
2 );

   setShowTitleParameters( 
false );


}