how to get signals from dll every one minute?

Questions about MultiCharts and user contributed studies.
tzsmile
Posts: 2
Joined: 04 Feb 2013

how to get signals from dll every one minute?

Postby tzsmile » 08 Feb 2013

I have a dll which get raw data from external data source and returns a signal in real time. Signals are 1(means buy), 0 (hold) and -1(sell). How can I get these signals from my dll to use in MC like every one minute? And how to plot it and execute it?
If there is a timer in Multicharts, then I can use the timer to call the dll every one minute and get signals, but I didn't find(maybe someone knows)
Or I can set a timer in my dll?
Can someone let me know? Thanks a lot

User avatar
Henry MultiСharts
Posts: 9165
Joined: 25 Aug 2011
Has thanked: 1264 times
Been thanked: 2957 times

Re: how to get signals from dll every one minute?

Postby Henry MultiСharts » 08 Feb 2013

Hello tzsmile,

In order to get a value from dll you need to use DefineDLLFunc reserved word.
How to use DefineDLLFunc:
“dll name”, the parameter dll returns, “the name of the function you refer to (inside the external dll)”, the type of the data you send to the external dll.

Example: "GlobalVariable.dll", float, "GV_GetFloat", int ;

The code is executed on each study calcualtion. If you need to generate orders then your study type should be Signal.
There are multiple ways the signals are calculated in MultiCharts. Please refer to the following article for more details:How_Signals_are_Calculated

tzsmile
Posts: 2
Joined: 04 Feb 2013

Re: how to get signals from dll every one minute?

Postby tzsmile » 08 Feb 2013

Thanks, but the problem is that the external data source is returning data at all times, so I need to use a timer through which I can call dll ,for example, every minute. Is there a timer in Multicharts or I can write the timer in my dll ?

Dru
Posts: 107
Joined: 28 Aug 2007
Has thanked: 4 times
Been thanked: 171 times

Re: how to get signals from dll every one minute?

Postby Dru » 11 Feb 2013

Tso I need to use a timer through which I can call dll ,for example, every minute. Is there a timer in Multicharts or I can write the timer in my dll ?
RecalcLastBarAfter can help


Return to “MultiCharts”