|
|
Is it possible to read MetaStock Files using C# [RESOLVED]
-
07-14-2006, 1:03 |
-
daydreamsy2k
-
-
-
Joined on 12-10-2005
-
-
Posts 7
-
-
|
Is it possible to read MetaStock Files using C# [RESOLVED]
hi
Is it possible to read MetaStock Files using C# (EMASTER, F1.DAT, F2.DAT .... )
I want to build an application that read the Intraday stock data from the DMetaStock Files
Thanks
|
|
-
07-14-2006, 2:40 |
-
wabbit
-
-

-
Joined on 10-28-2004
-
Perth, Western Australia
-
Posts 2,040
-
-
|
Re: Is it possible to read MetaStock Files using C# [RESOLVED]
Yes it is possible, but you need to have the MetaStock Developers Kit to be able to read the stored data format.
The question that should be asked is, what application are you trying to build? As there is always more than one to skin a cat, there is always more than one way to get the information you need.
If you provide a little more information about what you are trying to achieve, I am sure someone will provide you more help.
wabbit :D
"The question of whether a computer can think is no more interesting than the question of whether a submarine can swim." Edsgar W. Dijkstra MS: 6.52 EOD, 7.x EOD, 8.0 PRO, 9.2 PRO w/QC, 10 PRO w/QC C, 11 PRO w/QC & MDK For custom MetaStock programming : http://www.wabbit.com.au My SkyPE status :  My SkyPE account : wabbit.com.au
|
|
-
07-14-2006, 10:49 |
-
daydreamsy2k
-
-
-
Joined on 12-10-2005
-
-
Posts 7
-
-
|
Re: Is it possible to read MetaStock Files using C# [RESOLVED]
Thanks to you wabbit
I want to develop a small application that read the MetaStock Data Dir and when ever there is a change in the data it will read the data and store it in SQL Database
Thanks
|
|
-
07-14-2006, 22:59 |
-
jtrevatt
-
-
-
Joined on 05-25-2006
-
Brisbane, Australia
-
Posts 13
-
-
|
Is it possible to read MetaStock Files using C# (EMASTER, F1
Hi daydreamsy2k,
Wabbit asked me to respond. I have built a solution that seems to match what you are trying to do. I have build an MSX DLL. You need the MDK for more legal reasons that technical I think. I have two versions of the DLL in fact. One version outputs signals (including last price) directly to a SQL Server 2005 database, the other version outputs the signals to a TCP Server application that does some pre-processing before it writes to the database.e The frist thing you need to decide I think is whether you are going to build your DLL in C++, Delphi or PowerBASIC as the .NET languages and Active DLL's will not work. The DLL needs to be a native win32 DLL with no runtime dependencies. Once you have decided that you can probably create the DLL you need relatively quickly. Seeing as you already know about SQL and C# I wont bother talking about that side of it... the critical part is getting the info you want out of Metastock. I would suggest you look at the TCP (winsock) side of it rather than going direct to the DB... its important to make the round-trip your DLL does as short as possible, and TCP is probably the fastest method.
|
|
-
-
-
07-15-2006, 8:13 |
-
wabbit
-
-

-
Joined on 10-28-2004
-
Perth, Western Australia
-
Posts 2,040
-
-
|
spaceant,
You can purchase the MDK only directly from Equis. They will provide the MDK which has a users manual that contains some sample code. You have to have your own language compiler, C++, PowerBasic or Delphi to write MSX external functions, these or VisualBasic to access the MS File Library.
wabbit :D
"The question of whether a computer can think is no more interesting than the question of whether a submarine can swim." Edsgar W. Dijkstra MS: 6.52 EOD, 7.x EOD, 8.0 PRO, 9.2 PRO w/QC, 10 PRO w/QC C, 11 PRO w/QC & MDK For custom MetaStock programming : http://www.wabbit.com.au My SkyPE status :  My SkyPE account : wabbit.com.au
|
|
-
-
-
-
-
07-18-2006, 9:41 |
-
daydreamsy2k
-
-
-
Joined on 12-10-2005
-
-
Posts 7
-
-
|
jtrevatt: Hi, nice that you are enthusiastic. Just a slight correction though.. if you are replacing a true Metastock external library DLL then you need to exit Metastock before replacing it. Metastock puts a lock on it when it loads. I have experienced this personally. In your situation where your DLL seems not to be hosted by Metastock (is it a DLL still or an EXE?) then it obviously isnt constrained by this. I havent looked at reading metastock files but I guess there is no need for it to be running in-process if you are just polling the files for changes.
J
I did not mention that i want to replace the true MetaStock library !!!! ( No way .....)
I want to build a library that can be used in C# (managed code) to use the power of .NET
you know that with C#.NET SQL Database, ASP.NET, WebServices, Windows Services are just sooooo easy to implement.
Since i have the source of this CSharpMetaStock, I can use any where like make it work as Windows Services with out a user interface or as and EXE application that do what so every i ask it to do.
After I finish i will post this (CSharpMetaStock) as DLL and I will post also the source code for any body want to do more imporvements for Free
|
|
-
07-18-2006, 17:12 |
-
StorkBite
-
-
-
Joined on 03-19-2005
-
-
Posts 3,108
-
-
|
Re: Re: CSharpMetaStock.DLL
Maybe I'm not understanding the purpose of your dll, but the issue never was using .NET to interact with MSFL, but with MSX. There have been other posts containing examples on how to read and write data into an SQL database using .NET. The 'insurmountable' problem was with MSX. Is this what you have overcome?
Traders' Consortium
|
|
-
07-18-2006, 17:44 |
-
daydreamsy2k
-
-
-
Joined on 12-10-2005
-
-
Posts 7
-
-
|
StorkBite: Maybe I'm not understanding the purpose of your dll, but the issue never was using .NET to interact with MSFL, but with MSX. There have been other posts containing examples on how to read and write data into an SQL database using .NET. The 'insurmountable' problem was with MSX. Is this what you have overcome?
1. Read my first post again to understand the purpose [ @ the beginning the purpose was simple but now I have changed my maind to do more functions with this dll ]
2. Where is the post you are talking about for reading the and write data into an SQL database using .NET? (Please give me the link of the post may be it will help me)
3. What i the 'insurmountable problem with MSX? ( Please give more details )
===================================
2. Store the data in Microsoft Access ( DONE )
( CSharpMetaStock ) can now store the data in Microsoft Access
===================================
|
|
-
07-18-2006, 18:10 |
-
StorkBite
-
-
-
Joined on 03-19-2005
-
-
Posts 3,108
-
-
|
Hi DD2K-
I have a keen interest in your topic and I've read this thread more than a couple of times, but I became confused by your references to a .dll project. Certainly, .NET can interact with MSFL. With minor modifications, you can take the VS6 examples out of the MDK user's manual. You don't need to compile a dll to accomplish that task.
To the best of my recall, the aforementioned .NET project was removed from the forum d/l section so the author could pursue commercial development. There are other .NET applications commercially available, too, that interact with MSFL. You might try a Google search.
There are numerous posts on this forum in the Developers Forum about why .NET cannot be used to provide an MSX solution. The issue has been addressed by the Equis programming staff. I thought maybe you had come up with a unique way to accomplish that which wasn't supposed to be possible.
I wish you the best of luck in your current endeavor and look forward to seeing your charpmetastock project.
Traders' Consortium
|
|
-
07-18-2006, 20:31 |
-
jtrevatt
-
-
-
Joined on 05-25-2006
-
Brisbane, Australia
-
Posts 13
-
-
|
RE: Is it possible to read MetaStock Files using C# [RESOLVE
DD2K, I said that "if you are replacing a true Metastock external library DLL" with an emphasis on the "external". I was referring to a DLL that and user develops that is in compliance with the MSX specification laid out in the MDK. I was not referring to an Equis DLL shipped with Metastock.
In respect to the whole .NET/MSX DLL thing its probably and overdone subject now, but I pretty convinced that a .NET compiled DLL would not work as an MSX compliant DLL to be used in-process by Metastock. Equis have stated numerous times that only a native Win32 DLL would work. Please feel free to create an MSX compliant DLL in C# to prove them wrong. I have no objection to it at all... despite how easy it is to develop one in C++, PowerBASIC or Delphi I would love to use a .NET compiled DLL instead.
I can quite understand how easy it would be to use .NET to access the Metastock file format. All that would be involved would be in understanding the format and parsing out the data to SQL.
I have a question though - why bother? The real usefulness of Metastock is not in the price data you can suck out of it (because you can more easily get the data from another provider), but in how you use that data to make money. Why bother with getting the data out? Why not concentrate on getting your signals/alerts out instead? Im thinking as a trader here more than anything else. I am not in short-supply of data and in order to make money I have to concentrate on my signals/alerts... I just dont see any usefulness in getting the data repackaged.
J
|
|
-
07-19-2006, 20:43 |
-
daydreamsy2k
-
-
-
Joined on 12-10-2005
-
-
Posts 7
-
-
|
Re: RE: Is it possible to read MetaStock Files using C# [RES
jtrevatt:
Why bother with getting the data out? Why not concentrate on getting your signals/alerts out instead? Im thinking as a trader here more than anything else. I am not in short-supply of data and in order to make money I have to concentrate on my signals/alerts... I just dont see any usefulness in getting the data repackaged.
J
jtrevatt please do not bother your self with (CSharpMetaStock) because i did not do it for you.
Please Note:
1. I was thinking this forum is for developers who wnat to share ideas with each other.
2. I was developing this because i need it for my self.
3. When i have succeeded, i told my self why not put more functions on this and share it with other who need it or want do some thing in C# .NET ( Because i believe in that if you share your info with others, you gain more knowledge)
4. If you you think that only dll from Equis can do the analysis for you, you are wrong?
(Just look at this site http://www.ta4.net/ )
[Advertisement removed by Administration]
================================================================
End of the sotry: [ I was trying to help others not to bother any body who do not like the idea ]
There will be no more about this (CSharpMetaStock) in this forum
Thanks to all who help me on this
Kind Regards
|
|
-
07-19-2006, 23:22 |
-
jtrevatt
-
-
-
Joined on 05-25-2006
-
Brisbane, Australia
-
Posts 13
-
-
|
RE: Is it possible to read MetaStock Files using C# [RES
Hi dd2k,
First I apologize for obviously not phrasing myself properly. You obviously took what I said the wrong way. I believe there are plenty of people in this forum who would love to have access to your work. My question was quite sincere in its intent... that as a trader I would like to know what the value is in what your doing. Im sure you have a good reason to do it, I would just like to know what it is... it may give me ideas of my own. As far your point (4) goes.. I think you misinterpreted me again. The question again was not questioning IF you could do it but WHY you would do it. I can understand that if I put my technical hat on it would be a cool thing to do, but as a trader I have to justify WHY I would do it. How is it going to make me earn money?
Again, these are sincere questions, not confrontational ones.
J
|
|
-
-
01-01-2010, 14:55 |
-
01-03-2010, 5:20 |
|
|