Looking for either a python or R solution.
In R, I am able to retrieve DDE data into R from a third-party application using the following request:
library(tcltk2)
tk2dde.request(service = 'prortdde',topic='MNQXXXX', item='last')
"12262.75"
I'd like to continuously update this data. How can i create some kind of dde server or messaging system that would record all changes?
Including the above in a loop means losing data when updates are faster than loop execution... Thanks for any help.
In python, this is my current working code:
import win32ui
import dde
s=dde.CreateServer()
s.Create("prortdde")
c=dde.CreateConversation(s)
c.ConnectTo("prortdde", "MNQXXXX")
c.Connected()
c.Request("last")
# "12262.75"
BUT this will also miss values that are updated simultaneously (this occurs often). What I would need is some type of messaging system that would store all values, even those that are generated at the very same time, so that I can retrieve them later. Is that possible with DDE?