void ReqQryTradingAccount() { ThostFtdcQryTradingAccountField req = new ThostFtdcQryTradingAccountField(); req.BrokerID = BROKER_ID; req.InvestorID = INVESTOR_ID; int iResult = api.ReqQryTradingAccount(req); Console.WriteLine("--->>> 请求查询资金账户: " + ((iResult == 0) ? "成功" : "失败")); }
public void ReqTradingAccount() { var field = new ThostFtdcQryTradingAccountField(); int i = this.ReqQryTradingAccount(field, 0); if (i != 0) { LogCenter.Error("查询资金账户错误:" + CTPErrorHelper.GetError(i)); } }
public void QryAccount() { ThostFtdcQryTradingAccountField req = new ThostFtdcQryTradingAccountField(); req.BrokerID = this.BrokerID; req.InvestorID = this.UserID; var iResult = this.ReqQryTradingAccount(req, ++this.reqID); Console.WriteLine("--->>> 请求查询资金账户: " + ((iResult == 0) ? "成功" : "失败")); }
private void ReqQryTradingAccount() { var req = new ThostFtdcQryTradingAccountField { BrokerID = BrokerId, InvestorID = InvestorId }; var iResult = ReqQryTradingAccount(req, RequestId++); }
/* * -------------------------------------------------------------- * 查询函数:查持仓/查资金 * -------------------------------------------------------------- */ public void ReqQryTradingAccount() { Thread.Sleep(1000); ThostFtdcQryTradingAccountField req = new ThostFtdcQryTradingAccountField(); req.BrokerID = BROKER_ID; req.InvestorID = INVESTOR_ID; int ret = trader.ReqQryTradingAccount(req, ++iRequestID); HandleStatusInternal("CTP请求查询资金账户:" + (ret == 0 ? "成功" : "失败,返回代码" + ret)); }
/// <summary> ///请求查询资金账户 /// </summary> public int ReqQrySecAgentTradingAccount(ThostFtdcQryTradingAccountField pQryTradingAccount, int nRequestID) { return(Interop.TdReqQrySecAgentTradingAccount(Handle, pQryTradingAccount, nRequestID)); }
public static extern int TdReqQryTradingAccount(IntPtr pApi, ThostFtdcQryTradingAccountField pQryTradingAccount, int nRequestID);
/// <summary> /// 请求查询资金账户 /// </summary> void ReqQryTradingAccount() { ThostFtdcQryTradingAccountField req = new ThostFtdcQryTradingAccountField(); req.BrokerID = BROKER_ID; req.InvestorID = INVESTOR_ID; int iResult = api.ReqQryTradingAccount(req, ++iRequestID); Console.WriteLine("--->>> 请求查询资金账户: " + ((iResult == 0) ? "成功" : "失败")); }