Support Board
Date/Time: Sun, 24 Nov 2024 01:13:22 +0000
Post From: Buttons for the Spreadsheet System for Trading Buy Exit Sell Exit formulas
[2024-07-18 01:00:11] |
ForgivingComputers.com - Posts: 960 |
This code demonstrates how to read the value of another study. You can use this to set and control the stop. #include "sierrachart.h"
SCDLLName("Demo Get SG from Other Study") SCSFExport scsf_TemplateFunction(SCStudyInterfaceRef sc) { SCInputRef OtherStudyRef = sc.Input[0]; SCSubgraphRef SG_Subgraph = sc.Subgraph[0]; if (sc.SetDefaults) { sc.AutoLoop = 1; OtherStudyRef.Name = "Study ID/SG"; OtherStudyRef.SetStudySubgraphValues(32, 0); //ID32.SG1 SG_Subgraph.Name = "Subgraph"; } SCFloatArray OtherStudy; sc.GetStudyArrayUsingID(OtherStudyRef.GetStudyID(), OtherStudyRef.GetSubgraphIndex(), OtherStudy); // Result SG_Subgraph[sc.Index] = OtherStudy[sc.Index]; } Date Time Of Last Edit: 2024-07-18 01:01:49
|
Test_OtherStudy.cpp - Attached On 2024-07-18 00:59:27 UTC - Size: 618 B - 164 views |