DLL-fout 126
Results 1 to 2 of 2

Thread: DLL-fout 126

  1. #1
    Hoi,
    ik probeer een DLL te gebruiken van mijn EA in MT4 (Build 1010)
    ik schreef een DLL met behulp van C met VS 2015
    maar ik krijg altijd Fout 126
    ik heb geprobeerd het DLL-bestand in de map Gegevens te plaatsen (meer dan 600 mappen maken):
    C: \ Users \ XXX \ AppData \ Roaming \ MetaQuotes \ Terminal \ XXX \ MQL4 \ Bibliotheken
    en ik probeerde het in een andere map te plaatsen, geen geluk, ik krijg steeds 126 fouten
    mijn DLL voldoet aan 32 bit.

    mijn DLL-code is -
    stdafx.h:
    #pragma ��n keer
    # include targetver.h
    #define WIN32_LEAN_AND_MEAN/Sluit zelden gebruikte spullen uit Windows-headers uit
    # include lt; windows.hgt;
    //# define MT4_EXPFUNC __declspec (dllexport)/ik heb deze regel ook geprobeerd
    #define MT4_EXPFUNC extern C __declspec (dllexport)

    myDLL.cpp:
    # include stdafx.h
    # include lt; complexgt;
    MT4_EXPFUNC int mySum (int a, int b)
    {
    return a b;
    }
    MT4_EXPFUNC dubbele myPower (dubbele a, dubbele b)
    {
    return std:
    hoe (a, b);
    }

    mijn EA-code is:
    myEA.mq4:
    #import myDLL.dll
    int mySum (int, int);
    dubbele myPower (dubbel, dubbel);
    #importeren
    int OnInit ()
    {
    Afdrukken (teruggestuurd vanuit Sum in init-module, mySum (1,2));
    Print (terug van Power in init-module, myPower (2,2));

    terugkeer (INIT_SUCCEEDED);
    }
    void OnDeinit (const int reason)
    {
    }
    ongeldig OnTick ()
    {
    Afdrukken (teruggestuurd vanuit Som in startmodule, mySum (3,4));
    Afdrukken (terug van Power in startmodule, myPower (3,4));
    }

    Bedankt,
    Shay

  2. #2
    opgelost - ik compileer het naar RELEASE in plaats van DEBUG en in de debug-modus heb ik de Visual C Redistributable nodig (zoals ik begreep bij het zoeken op het web) Shay

Similar Threads

  1. MT4 Metatrade-fout?
    By alvaroabm in forum Cryptocurrencies
    Replies: 3
    Last Post: 18:54,
  2. OrderModify-fout
    By Rassexx in forum Cryptocurrencies
    Replies: 30
    Last Post: 07:10,

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
This website uses cookies
We use cookies to store session information to facilitate remembering your login information, to allow you to save website preferences, to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners.