我在OnInitDialog函数中注册了两个期权的行情数据如下两行(2月2150的认沽和认购), 但是在ReportUpdate函数中只能收到第一条10000522的行情更新,为什么 谢谢了? 我用的是免费版本。
//注册期权行情数据
g_pMainFormework->RegReportNotify("10000522",'QQ');
g_pMainFormework->RegReportNotify("10000520",'QQ');
void CMainWindowDlg::ReportUpdate(LPARAM l)
{
REPORT_STRUCT * pData = (REPORT_STRUCT*)l;
//显示处理报表 pData->m_fNewPrice ....
CString strTextName;
CString strText;
strTextName.Format("%s",pData->m_szLabel);
if(strTextName == "10000520")
{
strText.Format("注册品种: %s |申买价 %.4f |买量 %.4f |申卖价 %.4f |卖量 %.4f |", pData->m_szName, pData->m_fBuyPrice[0],pData->m_fBuyVolume[0],pData->m_fSellPrice[0],pData->m_fSellVolume[0]);
GetDlgItem(IDC_STATIC_TEXT)->SetWindowText(strText);
}
if(strTextName == "10000522")
{
strText.Format("注册品种: %s |申买价 %.4f |买量 %.4f |申卖价 %.4f |卖量 %.4f |", pData->m_szName, pData->m_fBuyPrice[0],pData->m_fBuyVolume[0],pData->m_fSellPrice[0],pData->m_fSellVolume[0]);
GetDlgItem(IDC_STATIC_TEXT2)->SetWindowText(strText);
}
}