Hello
I know that I use CTRL +R or a command line but, is it possible to use a code to reload the chart by itself. I need to do it at least every week for all my charts
Martin
Reloading charts: Is there a way to do it from code? [SOLVED]
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2222 times
Re: Reloading charts: Is there a way to do it from code?
Hello
I know that I use CTRL +R or a command line but, is it possible to use a code to reload the chart by itself. I need to do it at least every week for all my charts
Martin
put the commandline in your code.
Re: Reloading charts: Is there a way to do it from code?
Sure , that is what I would like to do. Don't see any MC code or function to reload.put the command line in your code.
My idea would be to reload the last day after each new session.
If sessionlastbar[1] then reload(day);
Martin
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2222 times
Re: Reloading charts: Is there a way to do it from code?
if you want a function,
then put the commandline in the function.
Nobody is stopping you from doing that.
then put the commandline in the function.
Nobody is stopping you from doing that.
- JoshM
- Posts: 2195
- Joined: 20 May 2011
- Location: The Netherlands
- Has thanked: 1544 times
- Been thanked: 1565 times
- Contact:
Re: Reloading charts: Is there a way to do it from code?
You can use the CommandLine() keyword for that. Here's a list of the different commands you can use.My idea would be to reload the last day after each new session.
If sessionlastbar[1] then reload(day);
Code: Select all
if (sessionlastbar[1]) then
CommandLine(".rld int=1 day);
Re: Reloading charts: Is there a way to do it from code? [SOLVED]
OK I will test it. If it work then it open up a lot. I never work with Commandline from the code. My understanding was it was used externally like I'm using to set a new scale(Although you might want to double-check this to see if my understanding was correct.)Code: Select all
if (sessionlastbar[1]) then
CommandLine(".rld int=1 day);
Martin