Development Environment

Setting up the Development Environment

You can use e.g. Microsoft Visual C++ 6.0 as compiler.

Proceed as follows to use the EPLAN 21 API:

Example

//Initialize Eplan
eplInitialize();

//Create session:
EplHandle hSession;
hSession = eplCreateSession();

if (hSession != EPL_ERROR)
{
    //Create licensing command
    EplHandle hcmdLicense = eplCreateCommand(hSession, L"EPLAN.EPLAN21.LICENSE");

    if (hcmdLicense != PL_ERROR)
    {
        //Set licensing key

        eplSetParam(hSession, hcmdLicense, EPL_PARAM_LICENSE_USERNAME, "IHR_LIZENZNAME", 0);
        eplSetParam(hSession, hcmdLicense, EPL_PARAM_LICENSE_USERNUMBER, "1234567890ABC", 0);

        //Execute licensing command
        if (eplExecuteCommand(hSession, hcmdLicense) != EPL_ERROR)
        {
            //Licensing successful
            ...
        }
        else
        {
            //Error treatment
            ...
        }
    }
    else
    {
        //Error treatment
        ...
    }
}
else
{
    //Error treatment
    ...
}
eplDeinitialize();