Login Page - Create Account

Support Board


Date/Time: Mon, 23 Dec 2024 04:05:25 +0000



Post From: Snapshot data

[2015-09-02 02:44:54]
User713273 - Posts: 409
Hi im trying to "match up" current 5 sec snapshot data that IB provides as I have seen different closing, openeing prices. Below is the source code ive been using to pull IB data.

reqid is unique tag for stock symbol
you can ignore temp_tv since it is for future functionality in IB.

static TagValueListSPtr temp_tv;
m_pClient->reqRealTimeBars(tick_container_.GetTickAccum(tick)->req_id,
temp_tick->contract, 5 /* 5 sec only */,
"TRADES", true /*Real Trading Hours*/, temp_tv);