免費論壇 繁體 | 簡體
公告:SCLUB雲端專屬主機己開放租用
分享
MT4程式(Program)專業代寫服務(請email:letgofortrading@gmail.com) 警告:文章內容可能有大便,不喜請勿入。請不要像動物一樣,不歡迎也請勿自行進來找碴和找大便。私人網頁,後果請自行負責~
返回列表 發帖

[工具] 分享一個 MC 讀取外部資料的外掛 DLL

最近因為有些原因 , 需要讀取外部的資料檔 ,  但又不想動用到 dataN , 所以本來是想用MC_IO.dll
拿來用  , 但是好像遇到一些問題 , 所以索性乾脆自己發展一組 , 只能適用於 MC 專業版 , 不適用於
MC 券商版 , x64 的部分個人有在用 , x86 的部分因為自己沒灌 , 所以就只提供不測試了 , 附上原始碼 .
是用免費的 Dev C++ 5.8.0 版編譯的 , 有做一些防護 , 以免像 MC_IO.dll 檔案不存在 MC 會有 crash
的風險

附上 Dev C++ 5.8.0 版的鏈結 , 這是一個免費的 C++ IDE 編譯器 , http://orwelldevcpp.blogspot.tw/




提供一個使用範例 :

vars: value2(0);     // file position pointer
vars: idx   (0);
vars: DigitStr("");


if LastBarOnChart and BarStatus(1)=2 then
  begin
        
     FileDelete( "e:\hello.txt" );
     
     value2 = 0;
     
     for idx=0 to 2000
       begin
      
           value2 = _FIO_ReadDigit( "filename.txt" , value2 , DigitStr );
           
           _FIO_Write( "e:\hello.txt", text(doublequote,DigitStr,doublequote,Spaces(30-Strlen(DigitStr)),  value2:8:0 ) , 1 );
           
       end;
     
  end;

轉貼
附件: 您需要登錄才可以下載或查看附件。沒有帳號?註冊  
!qqconnect:connect_viewthread_share_title!: !qqconnect:connect_viewthread_share_to_qzone!!qqconnect:connect_viewthread_share_to_qzone! !qqconnect:connect_viewthread_share_to_weibo!!qqconnect:connect_viewthread_share_to_weibo! !qqconnect:connect_viewthread_share_to_pengyou!!qqconnect:connect_viewthread_share_to_pengyou!
LMAX 顛覆外匯交易經驗/擊敗所有外匯經紀商

返回列表