Login Page - Create Account

Support Board


Date/Time: Fri, 26 Apr 2024 04:28:12 +0000



[Programming Help] - Problem is - background hides candles

View Count: 862

[2018-11-26 13:09:13]
User517260 - Posts: 97
I use in one study a few subgraphs:

SCSubgraphRef ID2_Background_Sub = sc.Subgraph[3];
SCSubgraphRef ID17_BuyCandle_Sub = sc.Subgraph[19];
SCSubgraphRef ID16_SellCandle_Sub = sc.Subgraph[20];


ID2_Background_Sub.Name = "ID2: Background";
ID2_Background_Sub.DrawStyle = DRAWSTYLE_BACKGROUND_TRANSPARENT;
ID2_Background_Sub.PrimaryColor = RGB(64,64,64);
ID2_Background_Sub.DrawZeros = false;
ID2_Background_Sub.DisplayNameValueInWindowsFlags = 0;

ID17_BuyCandle_Sub.Name = "ID17: BUY CANDLE";
ID17_BuyCandle_Sub.DrawStyle = DRAWSTYLE_COLOR_BAR_CANDLE_FILL;
ID17_BuyCandle_Sub.PrimaryColor = RGB(0, 157, 0);
ID17_BuyCandle_Sub.DrawZeros = false;

ID16_SellCandle_Sub.Name = "ID16: SELL CANDLE";
ID16_SellCandle_Sub.DrawStyle = DRAWSTYLE_COLOR_BAR_CANDLE_FILL;
ID16_SellCandle_Sub.PrimaryColor = RGB(64, 0, 64);
ID16_SellCandle_Sub.DrawZeros = false;

Problem is - background hides candles. If I use DRAWSTYLE_IGNORE for backgronud - I see normal colored candles, but I can't see background and colored candles same time - it is a problem, because I need to have only one study which draws background depend of time and colored candles. What I have to do to decide this problem? Thanks!
[2018-11-26 21:05:35]
Sierra Chart Engineering - Posts: 104368
Refer to the following ACSIL variable:
ACSIL Interface Members - Variables and Arrays: sc.DrawStudyUnderneathMainPriceGraph
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing
[2018-11-26 22:52:06]
User517260 - Posts: 97
I have following code in source cpp file:

  sc.GraphName = "Custom Indicator";
  sc.AutoLoop = 1;
  sc.GraphRegion = 0;
  sc.DrawZeros = false;
  sc.DrawStudyUnderneathMainPriceGraph = 1;
    
You may see on video https://youtu.be/C6rl-NyKJfs it does not matter value of sc.DrawStudyUnderneathMainPriceGraph. Green candles are drawing by my study, same study draws gray background. But as soon as I switch on background - all green bars become invisible - only red and blue bars as default colors of candles. I don't know what to do do see same time background and colored green candles. Please help me!
Date Time Of Last Edit: 2018-11-26 22:55:39
[2018-12-04 08:58:59]
User517260 - Posts: 97
Dear support, I didn't get reply from your side since 26 Nov 2018. Please reply me as soon as possible.
[2018-12-04 09:42:53]
Sierra Chart Engineering - Posts: 104368
You really need to use separate studies for coloring the bars and coloring the background because when a study is drawing a background , it is going to be drawn underneath the price bars. So if you are trying to color the bars also within the same study, that is a problem and you will not see the coloring.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing
Date Time Of Last Edit: 2018-12-04 09:43:25
[2018-12-04 09:53:25]
User517260 - Posts: 97
Ok, now it is clear, thanks for reply!

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account