- 精华
- 0
- 在线时间
- 280 小时
- UID
- 5525
- 积分
- 1473
- 帖子
- 429
- 阅读权限
- 60
- 注册时间
- 2009-9-22
- 最后登录
- 2022-5-23
- 精华
- 0
- UID
- 5525
- 积分
- 1473
- 帖子
- 429
- 主题
- 93
- 阅读权限
- 60
- 注册时间
- 2009-9-22
- 最后登录
- 2022-5-23
|
明天打算用以下指令测试,进一步明确什么时候能取到A_FreeMargin值。
Begin
If (BarStatus==2)
{ If (AccountDataExist)
{ FileAppend("C:\\Test6.Log",Text(CurrentBar)+"%"+DateToString(Date)+" "+TimeToString(CurrentTime));
FileAppend("C:\\Test6.Log"," % A_FreeMargin: "+IIFString(A_FreeMargin==InvalidNumeric,"N/A",Text(A_FreeMargin)));
FileAppend("C:\\Test6.Log"," % ContractUnit:"+Text(ContractUnit)+" MarginRatio "+Text(MarginRatio));
}
Else
{ FileAppend("C:\\Test6.Log",Text(CurrentBar)+"#"+DateToString(Date)+" "+TimeToString(CurrentTime));
FileAppend("C:\\Test6.Log"," # "+IIFString(A_FreeMargin==InvalidNumeric,"N/A",Text(A_FreeMargin)));
}
} Else
FileAppend("C:\\Test6.Log",Text(CurrentBar)+"*"+DateToString(Date)+" "+TimeToString(Time)+" CurrentCapital: "+Text(CurrentCapital)+" "+Text(ContractUnit)+" "+Text(MarginRatio));
End |
|