I am trying to search how to code in to an efs a "tool info button "and bottom left of the chart to get an easy access to an edit box to adjust the parameters easily . I did a search on tool box also info box and no luck. I want to put it in the efs below Any suggestions or links on how to do this . thanks
Announcement
Collapse
No announcement yet.
tool info button on chart
Collapse
X
-
Jason K.
Project Manager
eSignal - an Interactive Data company
EFS KnowledgeBase
JavaScript for EFS Video Series
EFS Beginner Tutorial Series
EFS Glossary
Custom EFS Development Policy
New User Orientation
-
i got it to start off with edit box and draw test box but it wont access edit box when i press it . It has something to do with the final command
function Test(){
preMain();
//or if you don't want askForInput() in preMain just call it here and remove the line above
//askForInput();
Code:/********************************************************* Alexis C. Montenegro © July 2003 Use and/or modify this code freely. If you redistribute it please include this and/or any other comment blocks and a description of any changes you make. **********************************************************/ var vEnv = null; function preMain() { setPriceStudy(true); setStudyTitle("Envelope"); setCursorLabelName("EnvUpr", 0); setCursorLabelName("EnvBas", 1); setCursorLabelName("EnvLwr", 2); setDefaultBarFgColor(Color.yellow, 0); setDefaultBarFgColor(Color.lime, 1); setDefaultBarFgColor(Color.yellow, 2); setDefaultBarThickness(2,0); setDefaultBarThickness(2,1); setDefaultBarThickness(2,2); setPriceStudy(true); askForInput();// checkVersion(1,"http://share.esignal.com/ContentRoot/ACM%20Test/Formulas/basicEnvelope.efs"); //Comment this line out if modifying the code var fp1 = new FunctionParameter("Length", FunctionParameter.NUMBER); fp1.setLowerLimit(1); fp1.setDefault(35); //Edit this value to set a new default var fp2 = new FunctionParameter("Offset", FunctionParameter.NUMBER); fp2.setDefault(0); //Edit this value to set a new default var fp3 = new FunctionParameter("Source", FunctionParameter.STRING); fp3.setName("Source"); fp3.addOption("Close"); fp3.addOption("High"); fp3.addOption("Low"); fp3.addOption("Open"); fp3.addOption("HL/2"); fp3.addOption("HLC/3"); fp3.addOption("OHLC/4"); fp3.setDefault("Close"); //Edit this value to set a new default var fp4 = new FunctionParameter("Type", FunctionParameter.BOOLEAN); fp4.setName("Exponential"); fp4.setDefault(false); //Edit this value to set a new default var fp5 = new FunctionParameter("Percent", FunctionParameter.NUMBER); fp5.setLowerLimit(0); fp5.setDefault(.5); //Edit this value to set a new default } function main(Length, Offset, Source, Type, Percent) { if (vEnv == null) vEnv = new EnvelopeStudy(Length, Offset, Source, Type, Percent); drawTextRelative(3,15," TEST "+"@URL=EFS:Test",Color.black,Color.yellow, Text.RELATIVETOLEFT|Text.RELATIVETOBOTTOM|Text.BOLD|Text.FRAME, "Arial",10,"Test"); /************************************************* Insert your code following this text block Use vEnv.getValue(EnvelopeStudy.UPPER) and vEnv.getValue(EnvelopeStudy.BASIS) and vEnv.getValue(EnvelopeStudy.LOWER) for your code **************************************************/ return new Array (vEnv.getValue(EnvelopeStudy.UPPER),vEnv.getValue(EnvelopeStudy.BASIS),vEnv.getValue(EnvelopeStudy.LOWER)); }
Comment
Comment