c++ 1st try

How to create strategies and indicators
Message
Author
murfinp
Posts: 3
Joined: Fri Mar 18, 2016 3:37 am

c++ 1st try

#1 Postby murfinp » Fri Mar 18, 2016 4:21 pm

Hi

I am just trying to build a core dlm ... code below ...

I am getting the following errors:

Warning 1 warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\strategy2\strategy2\strategyinterfaceunit.h 1110 Strategy2
Warning 2 warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\strategy2\strategy2\strategyinterfaceunit.h 1606 Strategy2
Warning 3 warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. c:\strategy2\strategy2\strategyinterfaceunit.h 1607 Strategy2
Error 4 error C2572: 'ObjectsDeleteAll' : redefinition of default parameter : parameter 2 c:\strategy2\strategy2\strategyinterfaceunit.h 1726 Strategy2
Error 5 error C2572: 'ObjectsDeleteAll' : redefinition of default parameter : parameter 1 c:\strategy2\strategy2\strategyinterfaceunit.h 1726 Strategy2

How do i resolve these please?

Thanks


==================================

#include "stdafx.h"
#include "stdlib.h"


#include <windows.h>

#include "StrategyInterfaceUnit.h"
#include "TechnicalFunctions.h"


EXPORT void __stdcall InitStrategy()
{
StrategyShortName("DemoStrategy");
StrategyDescription("Demo strategy that does nothing");
}

EXPORT void __stdcall DoneStrategy()
{

}

EXPORT void __stdcall ResetStrategy()
{

}

EXPORT void __stdcall GetSingleTick()
{

}

imamushroom
Posts: 33
Joined: Wed Jan 20, 2016 2:52 pm

Re: c++ 1st try

#2 Postby imamushroom » Mon Jul 10, 2017 3:21 am

Hi,

Try adding the option _CRT_SECURE_NO_WARNINGS to the Command Line of the VC++ Compiler Options. That should fix it.


Return to “FT API”

Who is online

Users browsing this forum: No registered users and 3 guests