以下是通达信帐户信息源码主图或图贴图随时掌握盈亏情况
估计许多同学,同时交易好几个股票,且分多次建仓,记性不太好的,得点开交易确认成本及其它信息,是不有点麻烦。
因此,做了个帐户表,做成副图或主图,都可以。不知是否有同学需要。
当然,因为没有调用交易软件相关信息,所以如成本、数量、股票名称等,得自己填写进去,并在交易后适时修改,以保证信息的准确性。
{帐户}
股一成本:=6; 股一数量:=1000; 股一收盘价:=”SH601106$C”;{中国一重}
股二成本:=7.12; 股二数量:=1000; 股二收盘价:=”SH601958$C”;{金钼股份}
股三成本:=11.39; 股三数量:=1000; 股三收盘价:=”SZ002785$C”;{万里石}
股四成本:=6.51; 股四数量:=1000; 股四收盘价:=”SH600175$C”;{美都能源}
股五成本:=9.5; 股五数量:=1000; 股五收盘价:=”SZ300301$C”;{长方照明}
{以上数据应根据自己所购股票的实际情况,交易成功后修改}
DRAWTEXT_FIX(C>0,0,0,0.15,0,’中国一重’),COLORCYAN;
DRAWTEXT_FIX(C>0,0,0,0.30,0,’金钼股份’),COLORYELLOW;
DRAWTEXT_FIX(C>0,0,0,0.45,0,’万里石’),COLORCYAN;
DRAWTEXT_FIX(C>0,0,0,0.60,0,’美都能源’),COLORYELLOW;
DRAWTEXT_FIX(C>0,0,0,0.77,0,’长方照明’),COLORCYAN;
{股票名称应与自己实际做修改}
股一盈亏:=INTPART((股一收盘价-股一成本)*股一数量);
股二盈亏:=INTPART((股二收盘价-股二成本)*股二数量);
股三盈亏:=INTPART((股三收盘价-股三成本)*股三数量);
股四盈亏:=INTPART((股四收盘价-股四成本)*股四数量);
股五盈亏:=INTPART((股五收盘价-股五成本)*股五数量);
股一盈亏比例:=(股一收盘价-股一成本)/股一成本*100;
股二盈亏比例:=(股二收盘价-股二成本)/股二成本*100;
股三盈亏比例:=(股三收盘价-股三成本)/股三成本*100;
股四盈亏比例:=(股四收盘价-股四成本)/股四成本*100;
股五盈亏比例:=(股五收盘价-股五成本)/股五成本*100;
股一涨跌:=CONST(股一收盘价-股一成本);
股二涨跌:=CONST(股二收盘价-股二成本);
股三涨跌:=CONST(股三收盘价-股三成本);
股四涨跌:=CONST(股四收盘价-股四成本);
股五涨跌:=CONST(股五收盘价-股五成本);
DRAWTEXT_FIX(C>0,0,0,0,0,’名称’),COLORYELLOW;
DRAWTEXT_FIX(C>0,0,0.13,0,0,’库存’),COLORYELLOW;
DRAWTEXT_FIX(C>0,0,0.26,0,0,’成本’),COLORYELLOW;
DRAWTEXT_FIX(C>0,0,0.39,0,0,’盈额’),COLORYELLOW;
DRAWTEXT_FIX(C>0,0,0.52,0,0,’盈比’),COLORYELLOW;
DRAWTEXT_FIX(C>0;0,0.65,0,0,’涨跌’),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.13,0.15,0,股一数量),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.13,0.30,0,股二数量),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.13,0.45,0,股三数量),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.13,0.60,0,股四数量),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.13,0.77,0,股五数量),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.26,0.15,0,股一成本),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.26,0.30,0,股二成本),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.26,0.45,0,股三成本),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.26,0.60,0,股四成本),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.26,0.77,0,股五成本),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.37,0.15,0,CONST(股一盈亏)),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.37,0.30,0,CONST(股二盈亏)),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.37,0.45,0,CONST(股三盈亏)),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.37,0.60,0,CONST(股四盈亏)),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.37,0.77,0,CONST(股五盈亏)),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.5,0.15,0,CONST(股一盈亏比例)),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.5,0.30,0,CONST(股二盈亏比例)),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.5,0.45,0,CONST(股三盈亏比例)),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.5,0.60,0,CONST(股四盈亏比例)),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.5,0.77,0,CONST(股五盈亏比例)),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.64,0.15,0,股一涨跌),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.64,0.30,0,股二涨跌),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.64,0.45,0,股三涨跌),COLORCYAN;
DRAWNUMBER_FIX(C>0,0,0.64,0.60,0,股四涨跌),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.64,0.77,0,股五涨跌),COLORCYAN;
总盈:=CONST(股一盈亏)+CONST(股二盈亏)+CONST(股三盈亏)+CONST(股四盈亏)+CONST(股五盈亏);
DRAWTEXT_FIX(C>0,0,0.8,0,0,’总盈额’),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.8,0.15,0,INTPART(总盈)),COLORCYAN;
总成本:=CONST((股一成本*股一数量)+(股二成本*股二数量)+(股三成本*股三数量)+(股四成本*股四数量)+(股五成本*股五数量));
总盈比:=总盈/总成本*100;
DRAWTEXT_FIX(C>0,0,0.8,0.32,0,’总盈比’),COLORYELLOW;
DRAWNUMBER_FIX(C>0,0,0.8,0.49,0,总盈比),COLORCYAN;
评论(0)