I am just getting started with MQL4. I have written a DDL in Delphi and I am now trying to call it from a MQL script. When I compile I get the following error:-
char - parameter definition expected.
In accordance with a tutorial I found I have created an include file with this code:-
#import "ForexCurrUpd.dll"
void PassOnCSVString(char* currupdstr);
#import
then a script as follows:-
#include <DelphiCurrUpdate.mqh>
int start()
{
PassOnCSVString("Hello from Meta");
return(0);
}
Can anyone explain the error message and how to resolve it.
Thanks
Ron
i dont know what you do in #include <DelphiCurrUpdate.mqh> but i was writing a dll in Delphi also and was calling like this from an EA and passing lot of parameters without problems.
you was trying sting in case of char in you declaration?
#import "viper.dll"
int WriteSet(string Pair,int CF,int VOL1_3,int VOL1_5,int VOL1_7,int VOL3_5,int CANDLE1,int CANDLE2,int CANDLE3,int SLOPE1_3,int SLOPE1_5,int SLOPE1_7,int SLOPE3_5,int PROFIT,int VOLA1,int VOLA1_3);
int ReadSet(string Pair,int CF,int VOL1_3,int VOL1_5,int VOL1_7,int VOL3_5,int CANDLE1,int CANDLE2,int CANDLE3,int SLOPE1_3,int SLOPE1_5,int SLOPE1_7,int SLOPE3_5,int C,int VOLA1,int VOLA1_3);
#import

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
I am just getting started with MQL4. I have written a DDL in Delphi and I am now trying to call it from a MQL script. When I compile I get the following error:-
char - parameter definition expected.
In accordance with a tutorial I found I have created an include file with this code:-
#import "ForexCurrUpd.dll"
void PassOnCSVString(char* currupdstr);
#import
then a script as follows:-
#include <DelphiCurrUpdate.mqh>
int start()
{
PassOnCSVString("Hello from Meta");
return(0);
}
Can anyone explain the error message and how to resolve it.
Thanks
Ron