Hello,
I'm doing a project that retrieves data from the Betfair website, through the ESA API: https://docs.developer.betfair.com/display/1smk3cen4v3lu3yomq5qye0ni/Exchange+Stream+API
In this link above there is an example in C #, I downloaded, adapted the code and generated a DLL. The goal is to receive / send information on the Betfair server in real time, in this DLL it is recording the information it receives from the server in a Log.txt, and it is working perfectly.
I managed to connect this DLL to the powerbuilder, through:
OLEObject example
example.ConnectToNewObject ('Betfair.dll')
example.Start ()
// It started recording in Log.txt the information I need in a DW.
My question: How can I bring this data to a DataWindow? The idea of creating a 1second Timer and updating the information is not feasible for me. I need the powerbuilder to retrieve the information as soon as it updates.
I don't know if I made my question clear, but thanks in advance. A translator was used, so I apologize if anything is not clear.
As I understand you right you want to send a string to your application. (I thought you simply want to inform your application to read new information from log file.)
If you want to send the data with SendMessage I think it's not the best way to send each byte of string. Maybe it is better to send a pointer to the string (see https://social.msdn.microsoft.com/Forums/vstudio/en-US/b495207b-03bd-4fef-ad77-5b0669dab49a/how-to-pass-string-using-sendmessage?forum=vcgeneral).
In your Powerbuilder application you can receive the string from te pointer (see https://community.appeon.com/index.php/qna/q-a/receive-string-data-from-c-sendmessage)
But: I'm not a C# expert!
Regards,
René