Category : algorithmic-trading

I’m trying to get historical data of forex contract (what doesn’t need any subscription) and get std::bad_alloc at m_pClient->reqHistoricalData(4001, contract, queryTime, "1 M", "1 day", "TRADES", 1, 1, false, TagValueListSPtr()); Here is the whole code: #include "stdafx.h" #include <Contract.h> #include <Order.h> #include <OrderState.h> #include <Execution.h> #include <CommissionReport.h> #include <ScannerSubscription.h> #include <executioncondition.h> #include <PriceCondition.h> #include <MarginCondition.h> ..

Read more

I am new in C++. I am trying to run a code from stackoverflow https://github.com/Chudleyj/AlgoBot . When I run the code it crashes. Can anyone help me. Here is the code (IEX.cpp). Json::Value IEX::stats::historicalDaily(std::string date) { Json::Value jsonData; std::string url(IEX_ENDPOINT); std::locale loc; //For isdigit if(!date.empty()) { if(date.size() == 8) { url += "/stats/historical/daily?date="+date; IEX::sendGetRequest(jsonData, url); ..

Read more