Hi,
Do you have any sample code or suggestions on how to make data communications from MultiCharts.NET to another program? For example I'm trying to use a WPF application to receive and display messages coming from MC.NET which I can use instead of the MC.NET's output window. I would prefer a communication method that allows the external program to run independently from the PowerLanguage project using a standard service model or protocol. Some of the solutions that I can think of are WCF or any of the REST libraries available but I haven't used any of them and specifically don't know how to use them with MC.NET. Has anybody done this before?
Thanks,
-orad
Communicating from MultiCharts.NET with another .NET program [SOLVED]
- Henry MultiСharts
- Posts: 9165
- Joined: 25 Aug 2011
- Has thanked: 1264 times
- Been thanked: 2958 times
Re: Communicating from MultiCharts.NET with another .NET pro
Hi Henry, yes I have tried that but it's not what I'm looking for as it makes the PowerLanguage.NET project tightly coupled with the external program. I was wondering if anybody has tried a service model communication to send/receive data with the PL.NET project.
-
- Posts: 81
- Joined: 29 Apr 2013
- Location: www.threefoldmarkets.com
- Has thanked: 12 times
- Been thanked: 16 times
- Contact:
Re: Communicating from MultiCharts.NET with another .NET pro [SOLVED]
Yes, you can use the built in .NET internet API to send data to a website. Include
using System.IO;
using System.Net;
You have to write software to call "System.Net.ServicePointManager" and software on the server to receive. If you are not a software developer this may be a challenge. I do this to manage license subscriptions to my strategy services.
using System.IO;
using System.Net;
You have to write software to call "System.Net.ServicePointManager" and software on the server to receive. If you are not a software developer this may be a challenge. I do this to manage license subscriptions to my strategy services.
-
- Posts: 26
- Joined: 30 Jan 2014
- Been thanked: 4 times
Re: Communicating from MultiCharts.NET with another .NET pro
MC.net also opens the door to implementing database, such as MSSSQL, or MSSQL Express(file based).
Re: Communicating from MultiCharts.NET with another .NET program
Is there any sample code or project we may reference or build on? A lead will be truly appreciated!
Re: Communicating from MultiCharts.NET with another .NET program
Hi,
When I need to communicate quickly with few information, I am using a solution of FX1 :
I am using Xls gate to communicate easly through an excel sheet between application :
http://xlsgate.com/
https://fx1.net/sharedvar.php
https://fx1.net/products.php#
However when I need real communication between DLL/EXE I use a PIPE solution :
Here you have example :
https://dotnetcodr.com/messaging/
https://dotnetcodr.com/2015/06/16/basic ... ngle-byte/
https://dotnetcodr.com/2015/06/17/basic ... unication/
https://dotnetcodr.com/2015/06/18/vario ... y-pattern/
https://dotnetcodr.com/2015/06/19/basic ... nsmission/
https://dotnetcodr.com/2015/06/23/basic ... -messages/
https://dotnetcodr.com/2015/06/24/basic ... g-objects/
https://dotnetcodr.com/2015/06/26/basic ... mpression/
another great example :
https://www.codeproject.com/Articles/11 ... -Named-Pip
When I need to communicate quickly with few information, I am using a solution of FX1 :
I am using Xls gate to communicate easly through an excel sheet between application :
http://xlsgate.com/
https://fx1.net/sharedvar.php
https://fx1.net/products.php#
However when I need real communication between DLL/EXE I use a PIPE solution :
Here you have example :
https://dotnetcodr.com/messaging/
https://dotnetcodr.com/2015/06/16/basic ... ngle-byte/
https://dotnetcodr.com/2015/06/17/basic ... unication/
https://dotnetcodr.com/2015/06/18/vario ... y-pattern/
https://dotnetcodr.com/2015/06/19/basic ... nsmission/
https://dotnetcodr.com/2015/06/23/basic ... -messages/
https://dotnetcodr.com/2015/06/24/basic ... g-objects/
https://dotnetcodr.com/2015/06/26/basic ... mpression/
another great example :
https://www.codeproject.com/Articles/11 ... -Named-Pip
Re: Communicating from MultiCharts.NET with another .NET program
there are quite a few ways for MC and MC.Net to communicate with other applications. Imho FX1 is using memory mapped files as I do. When I was researching this years back I came to the conclusion to write my own communication middleware instead of relying on FX1 or alike, even though it seems to be very good.
What I did was using memory mapped files (acting as virtual memory which is persisted on the SDD) to store binary and/or txt-based data, handled in a SharedData.dll + InteropLib. It got way bigger in the meanwhile but for everyone wanting to write own interaction between MC/MC.Net with other applications the concept of memory mapped files is very useful and a simple version not that difficult to implement. This way its easy for any application to just grab the DLL and add / fetch some data of the MMF or do a messaging system.
What I did was using memory mapped files (acting as virtual memory which is persisted on the SDD) to store binary and/or txt-based data, handled in a SharedData.dll + InteropLib. It got way bigger in the meanwhile but for everyone wanting to write own interaction between MC/MC.Net with other applications the concept of memory mapped files is very useful and a simple version not that difficult to implement. This way its easy for any application to just grab the DLL and add / fetch some data of the MMF or do a messaging system.
Re: Communicating from MultiCharts.NET with another .NET program
PK1 ,
I wanted to develop mapped memory as well. but I didn't find any example .
Do you have an example of mapped memory ? This would be very helpful . because I need as well to communicate with other application.
This would be much better than using an application of FX1.
I wanted to develop mapped memory as well. but I didn't find any example .
Do you have an example of mapped memory ? This would be very helpful . because I need as well to communicate with other application.
This would be much better than using an application of FX1.
Re: Communicating from MultiCharts.NET with another .NET program
Dear Emmanuel PK1, any chance may share the link as well? Thank you so much!
Re: Communicating from MultiCharts.NET with another .NET program
rc76,
Here are the links plus other one:
https://coders-corner.net/2013/03/25/in ... fe-access/
https://docs.microsoft.com/en-us/dotnet ... pped-files
https://docs.microsoft.com/en-us/dotnet ... /pipelines
https://docs.microsoft.com/en-us/dotnet ... operations
https://docs.microsoft.com/en-us/dotnet ... ew=net-5.0
https://docs.microsoft.com/en-us/dotnet ... munication
https://docs.microsoft.com/en-us/dotnet ... ew=net-5.0
https://docs.microsoft.com/en-us/dotnet ... munication
https://docs.microsoft.com/en-us/dotnet ... ew=net-5.0
I hope this will help
Here are the links plus other one:
https://coders-corner.net/2013/03/25/in ... fe-access/
https://docs.microsoft.com/en-us/dotnet ... pped-files
https://docs.microsoft.com/en-us/dotnet ... /pipelines
https://docs.microsoft.com/en-us/dotnet ... operations
https://docs.microsoft.com/en-us/dotnet ... ew=net-5.0
https://docs.microsoft.com/en-us/dotnet ... munication
https://docs.microsoft.com/en-us/dotnet ... ew=net-5.0
https://docs.microsoft.com/en-us/dotnet ... munication
https://docs.microsoft.com/en-us/dotnet ... ew=net-5.0
I hope this will help
Re: Communicating from MultiCharts.NET with another .NET program
I haven't decide yet, most likely I plan to write something up like a WPF/Winform as a helper addon like TS can do.
Will keep you posted once I got prototype up
Will keep you posted once I got prototype up