Data via DDE; DDE application & Metastock

 
Hi.
1)
I'm not sure how to get the following real-time data by DDE:
- open
- close
- volume
- only date
- only time

2)
I have Metastock 9.
I opened MetaTrader 4.
I downloaded the DDEChartUpdater and set it up in vain.
The setting is:
Name: EURUSD
Symbol: EURUSD

Intraday
1 Minute
C:\MetaStock Data\Forex

DDE Server: MT4
Time: =MT4|TIME!EURUSD
Close =MT4|!BID!EURUSD
(I couldn't find a way to get the Close data.)

After that, the error message showed:
EURUSD: Failed to connect to the DDE server "MT4"! Make sure that the application providing the quotes is running
EURUSD: Failed to connect! The topic "" does not exist, or the item "BID!EURUSD" does not exist

What's up?
 
Hi.
1)
I'm not sure how to get the following real-time data by DDE:
- open
- close
- volume
- only date
- only time

2)
I have Metastock 9.
I opened MetaTrader 4.
I downloaded the DDEChartUpdater and set it up in vain.
The setting is:
Name: EURUSD
Symbol: EURUSD

Intraday
1 Minute
C:\MetaStock Data\Forex

DDE Server: MT4
Time: =MT4|TIME!EURUSD
Close =MT4|!BID!EURUSD
(I couldn't find a way to get the Close data.)

After that, the error message showed:
EURUSD: Failed to connect to the DDE server "MT4"! Make sure that the application providing the quotes is running
EURUSD: Failed to connect! The topic "" does not exist, or the item "BID!EURUSD" does not exist

What's up?


First, we are sunday, wait a little bit to have some tick...
 
For me all is perfectly working, but the MT4's time format is not accepted by DDEChartUpdater: if you are using a tick-chart, all is ok.

Create a MS tick chart with The Downloader, wich name is EURUSD, then open it. MS9 must be set on "No Vendors" and run it "offline mode". Tools > Options > RealTime > Enable live Bars must be checked then grayed by the offline mode running.

Run MT4, be sure the MT4's DDE Enable checkBox is checked, and the MS chart is already opened.
Then open DDEChartUpdater and add a new symbol. Fill the "Stock information" zone and uncheck all CBoxes of the DDE settings.

Hope this help...

Another way without all that DDE stuff is to use Metalib.dll (from TradingTools) in a script running on MT4 : you should be able to export what you want directlly to the MS files. But I haven't tried yet....
 
For me all is perfectly working, but the MT4's time format is not accepted by DDEChartUpdater: if you are using a tick-chart, all is ok.

Create a MS tick chart with The Downloader, wich name is EURUSD, then open it. MS9 must be set on "No Vendors" and run it "offline mode". Tools > Options > RealTime > Enable live Bars must be checked then grayed by the offline mode running.

Run MT4, be sure the MT4's DDE Enable checkBox is checked, and the MS chart is already opened.
Then open DDEChartUpdater and add a new symbol. Fill the "Stock information" zone and uncheck all CBoxes of the DDE settings.

Hope this help...

Another way without all that DDE stuff is to use Metalib.dll (from TradingTools) in a script running on MT4 : you should be able to export what you want directlly to the MS files. But I haven't tried yet....


As to time format, is it true there's no way for DDEChartUpdater to retrieve it correctly (as it doesn't provide the format used by MT4? I set it as tick, but it's still not ok. The same "time format error" keeps popping. Without time infomration, how can we build a correct Metastock file ?_?

As to Metastock Downloader, what's start & end time should I fill?

How can I fill the close / volume / open information?
Your example provided in DDE Sample.xls doesn't show how to get these data!


===================

I failed to update my chart! No update was made.
Here's what I did:

1) Open Metastock Offline -> Select Tools | The Downloader
2) In Downloader, Select File | New | Security
3) In the dialog,
Name / Symbol: EURUSD
Periodicity: intraday
Unit: Decimal
Interval:Tick
Star time: (follow the default) 12:00AM
End time: (follow the default) 12:00AM
- Then press "create"
4) Open EURUSD file

5) Open MetaTrader
6) DDE Enable checkBox is checked
7) Open the chart of EURUSD

8) Open DDEChartUpdater. Select "Symbol | Add"
9) The setting is:
Name: EURUSD
Symbol: EURUSD

Intraday
Tick
C:\MetaStock Data\Forex

DDE Server: MT4
Time: =MT4|TIME!EURUSD
Close =MT4|!BID!EURUSD (I couldn't find a way to get the Close data.)
{No checkbox is enabled}

The Metastock file created is still empty.
The chart is not updated automatically.
But I can see the close value flashing in DDEChartUpdater.
 
"But I can see the close value flashing in DDEChartUpdater."
Nice, this is the half part of the trick !
Please, verify those points :
- The MS9 file EURUSD is in the same folder than the one specified in DDEChartUpdate
- StartTime and EndTime are both 00:00 (I don't know if it's important or not, but maybe...)
- In MS9, go to Tools/Options/RealTime then check both Enable real-time and Enable live bars.
- Restart MS9 : you will get some message saying it cannot connect etc. Choose "Work offline".
- Open your EURUSD chart, (and verify it's the good one)
- Start MT4
- Start DDEChartUpdater and wait few ticks : verify you don't get any error message, now you must see the live chart !

Of course, I assume you have a real-time version of MS9 (e-Signal Sharework ?), not the off-line version ! It's really different to run the real-time version in offline mode and to run the offline version.
 
"But I can see the close value flashing in DDEChartUpdater."
Nice, this is the half part of the trick !
Please, verify those points :
- The MS9 file EURUSD is in the same folder than the one specified in DDEChartUpdate
- StartTime and EndTime are both 00:00 (I don't know if it's important or not, but maybe...)
- In MS9, go to Tools/Options/RealTime then check both Enable real-time and Enable live bars.
- Restart MS9 : you will get some message saying it cannot connect etc. Choose "Work offline".
- Open your EURUSD chart, (and verify it's the good one)
- Start MT4
- Start DDEChartUpdater and wait few ticks : verify you don't get any error message, now you must see the live chart !

Of course, I assume you have a real-time version of MS9 (e-Signal Sharework ?), not the off-line version ! It's really different to run the real-time version in offline mode and to run the offline version.


First of all, thanks so much for your kind help!

Here's my answer to your question:
- Both (MS9 & DDEChartUpdater) are set at: C:\MetaStock Data\Forex
- Yes, both are set at 12:00am
- Yes, all checboxed are checked by default.
- Hey, should I choose Metastock Pro Offline Mode, or just Metastock Pro [real-time mode]? Anyway I chose just Metastock Pro -> loading -> Clicked "work offline"
- I closed all applications. Open MS9 Pro [real-time mode]! Open MT4! Open DDEChartUpdater!
- The error message I received from DDEChartUpdater is "Invalid Time: The time must have the following format: HH:MM:SS..."

The chart is still empty :(

I wonder if the problem is due to the following:
- the inability to get open/close/volume from MT4 via DDE
- the time format error

Any clue?
 
You receive a error message about time format from DDEChartUpdater because you try to get it, but it's not posible due to the format incompatibility : select the Symbol then Edit it : clear the Time topic inputbox and uncheck the Time checkbox ; Try first to update a tick-chart : the only topic you need to receive is the Close (=MT4|BID!EURUSD). Leave unchecked the Update stock only between... cbox.Then restart DDECU. So I hope you are returned to the situation where you see the close value flashing in DDEChartUpdater.
Now close all and restart first MS9, then MT4, then DDECU.
"Anyway I chose just Metastock Pro -> loading -> Clicked "work offline"" : I do the same and it's ok.
 
You receive a error message about time format from DDEChartUpdater because you try to get it, but it's not posible due to the format incompatibility : select the Symbol then Edit it : clear the Time topic inputbox and uncheck the Time checkbox ; Try first to update a tick-chart : the only topic you need to receive is the Close (=MT4|BID!EURUSD). Leave unchecked the Update stock only between... cbox.Then restart DDECU. So I hope you are returned to the situation where you see the close value flashing in DDEChartUpdater.
Now close all and restart first MS9, then MT4, then DDECU.
"Anyway I chose just Metastock Pro -> loading -> Clicked "work offline"" : I do the same and it's ok.


Yes, it should be due to format incompatibility .

Actually, even if the time format incompatibility exists, the close is still flashing. It is just the Metastock file is always empty.

Every checkbox is unchecked.

Let's see if it works now.
 
Don't be boring with the time format : let DDEUC compute the date and time itself. I am working now simultaneously with tree live MS9 charts, all EURUSD, one is a tick chart, another a one min, and the last a 5 min intervall. On the two last, I leave DDEUC compute the OHLC values itself, checking the "Automatically calculate open, high, low prices" ; the only I cannot retrieve is the Volume. All are perfectly working, so, say you it's possible and even easy !
 
Don't be boring with the time format : let DDEUC compute the date and time itself. I am working now simultaneously with tree live MS9 charts, all EURUSD, one is a tick chart, another a one min, and the last a 5 min intervall. On the two last, I leave DDEUC compute the OHLC values itself, checking the "Automatically calculate open, high, low prices" ; the only I cannot retrieve is the Volume. All are perfectly working, so, say you it's possible and even easy !


Thanks so much, MichelB!
It works like a charm! Haha...
You are my day-saver! :P

The only sad thing is we couldn't be able to retrieve volume information. It's hard to imagine MetaTrader couldn't support this via DDE. (I've read its DDE sample. There's no command which can get volume which is strange!)

Strictly, we should get Last instead of Bid, but again I couldn't find any way to get Last.

Now Metastock can update in real-time (by keep flashing its chart). But I'm a bit dizzy at the flashing chart! X) Have to lower its refreshing rate :)

Actually you can skip the step of creating new files in Metastock.
Just go to DDEChartUpdater and set it up. It will create for you automatically.
 
Do you know how to download the tick data of different currency pairs later after I log-on?
It seems to me I need to be always on in order to get all tick data.
Any clue?

After all, thanks so much for your help!

Do you have any email address?
If so, could you mind giving your email address (don't type the @ or spambot will spot this email ddress out)?
So if I have further questions regarding DDEChartUpdater. I could email you.
I look forward to your reply. :)
Reason: