PanagiotisCharalampous's avatar
PanagiotisCharalampous
26 follower(s) 0 following 1006 subscription(s)
Replies

PanagiotisCharalampous
21 Sep 2024, 06:13

RE: RE: How to create a cBot using a custom indicator

a.datawhip said: 

PanagiotisCharalampous said: 

Hi there,

Indicators without source code cannot be referenced.

Best regards,

Panagiotis

Does this mean , there is no way to use a custom indicator within a cBot like we do with meta trader?

You can but you need to have the source code.


@PanagiotisCharalampous

PanagiotisCharalampous
21 Sep 2024, 06:12

RE: RE: RE: RE: RE: RE: Check if position has already been opened and closed?

rick2010 said: 

Thanks… so as soon as a trade is closed it is instantly added to the historical? If it's instant this solution will work…. but if there is a delay of say more than 1 second then I'll have to keep them in a list in my code.

PanagiotisCharalampous said: 

Check the link below

https://help.ctrader.com/ctrader-algo/references/Trading/History/History/#examples

Yes it should be added instantly


@PanagiotisCharalampous

PanagiotisCharalampous
21 Sep 2024, 06:11

RE: cTrader Not Opening - Win 10

collett.salento said: 

I've encountered exactly this problem today. Desktop was working fine first thing, looked at something else, and when I went back to Desktop all that I could get was this white box. Have tried clean uninstall/reinstall etc as per instructions several times, but all that I ever get is the white box now (sometimes black) over the task bar. No actual screen in any shape or form, though I always get the ‘workspace has loaded successfully’ message on alleged booting up. Broker is mystified. Any ideas?

Hi there,

Did you try a clean installation?

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
20 Sep 2024, 13:32

RE: RE: RE: RE: Check if position has already been opened and closed?

rick2010 said: 

PanagiotisCharalampous said: 

There is no option to access closed positions. You can only access past deals through History. Nevertheless if you want the information to persist between cBot restarts, you can always save it in a file

Do you have a code example of getting a trade out of history? Can it be done using a name or id? TIA

 

 

 

Check the link below

https://help.ctrader.com/ctrader-algo/references/Trading/History/History/#examples


@PanagiotisCharalampous

PanagiotisCharalampous
20 Sep 2024, 13:30

RE: RE: How do you hide the indicator text list so that it does not interfere with chart drawings?

mryao said: 

Hi, you misunderstand me. I don't want them to change color or become invisible. I don't want the list on the screen so that when I move my SL/TP - they don't get in the way.

 

PanagiotisCharalampous said: 

Hi there,

Here you go

 

Did you try my suggestion? When you uncheck that option, the list will disappear


@PanagiotisCharalampous

PanagiotisCharalampous
20 Sep 2024, 05:43

Hi there,

Here you go


@PanagiotisCharalampous

PanagiotisCharalampous
20 Sep 2024, 05:41

Hi Waxy,

Please send us some troubleshooting information the next time this happens, and paste a link to this discussion inside the text box before you submit it.

Best regards,

Panagiotis
 


@PanagiotisCharalampous

PanagiotisCharalampous
20 Sep 2024, 05:37

Hi there,

Indicators without source code cannot be referenced.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
20 Sep 2024, 05:31

RE: RE: Check if position has already been opened and closed?

rick2010 said: 

PanagiotisCharalampous said: 

Hi there,

You can track the closed positions using the Positions.Closed event. There you can add the closed positions in a collection as the one you posted above.

Best regards,

Panagiotis

Thanks… I don't care about the event, I need to be able to look up a history of closed/filled trades. For example before placing a trade for id XYZ123 I first need to make sure that trade id XYZ123 hasn't already been opened and closed… this is to prevent duplicate trades from occurring. And if I just add them to a collection I'll lose that collection of closed trades next time the cBot is restarted which will allow duplicate trades to occur. TIA

 

There is no option to access closed positions. You can only access past deals through History. Nevertheless if you want the information to persist between cBot restarts, you can always save it in a file


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 12:19

Hi there, 

There is nothing special you need to do. Just launch cTrader two times and use the account you want on each instance.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 12:17

Hi there,

Could you please send us some troubleshooting information the next time this happens? Please paste a link to this discussion inside the text box before you submit it.

Best regards,


 


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 09:35

RE: Display indicator on unhide -Code

VIZAINT said: 

Nothing out of the ordinary, there is a method of creating the box and then in Calculation it is repeated 10 times, to form part of the vertical line on the right.

public override void Calculate(int index) {
for (int ib = 0; ib < 10; ib++)
               {
                   ////////////
                   ///---------------
                  ///////////

                   DrawMyRectangle(ib, index, Start, End, currentPrice, by10, MaxBoxIndex, MinBoxIndex);

               }
}

 

public ChartRectangle DrawMyRectangle(int ib, int ind, int start, int end, double currPrice, double by10, double MaxBoxIndex, double MinBoxIndex)
       {
           double sum = Xcind(ind, start, end);
           List<double> mSum = new();
           mSum.Add(sum);

           var Minut = TimeFrame.GetHashCode();
           var newOffset = Minut * OffsetBox;
           var topbx = by10 - (by10 * 0.1);
           var btmbx = by10 - (by10 * 0.9);
           var newColor = sum > 0 ? Color.FromArgb(TranspBox, UpColor) : Color.FromArgb(TranspBox, DownColor);

          ////////////
          ///---------------
         ///////////

           return rec;
       }

hi there,

I would need the full source code of the indicator to assist further


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 06:39

Hi there,

You should ask your broker to investigate from where these orders were executed. The broker can see from which application was the position opened. This could help you understand what is going on.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 06:36

Hi there,

Could you please send us some troubleshooting information the next time this happens? Please paste a link to this discussion inside the text box before you submit it.

Best regards,

Panagiotis


 


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 06:35

Hi there,

Please share your indicator code so that we can reproduce it.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 06:34

RE: Horizontal Line - Price Level

BlackGesusTrading said: 

bro now its automatically hidden and I don't know how to find where to unhid it …. ive been struggling for 3 days now and can't find the awnser no where… anybody can help me?

Hi there,

Can you share a screenshot of what you are looking at?

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 06:31

Hi there,

This feature is not available yet in cTrader for Mac.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 06:11

Hi there,

You can track the closed positions using the Positions.Closed event. There you can add the closed positions in a collection as the one you posted above.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 05:48

Hi there,

The problem is that your are calling a property that does not exist. Bars do not have a Volume property.

Best regards,

Panagiotis


@PanagiotisCharalampous

PanagiotisCharalampous
19 Sep 2024, 05:38

Hi there,

Feel free to share your code so that we can advise you what the issue is.

Best regards,

Panagiotis


@PanagiotisCharalampous