📄 新建 文本文档.txt
字号:
CFormBase::load();
//遍历一次向量容器,将账户打印出来
CConManager &conman=CConManager::GetInstance();
int consize;
consize=conman.GetSize();
vector<CConsume> tempvec;
GotoXY(18,12);
cout<<"Input Date From :"<<ends;
GotoXY(18,14);
cout<<"Input Date To :"<<ends;
GotoXY(18,12);
do
{
string formdate=InputDate();
string todate=InputDate();
if(CMyString::DateCompare(fromdate,todate)>=0)
{
CMessageBox::ShowMessage("Your input is illegal,please input again.");
continue;
}
else
break;
}while(1);
for (int i=0;i<consize;i++)
{
if(CMyString::DateCompare(conman.GetConsume(i).GetDate,fromdate)>=0&&CMyString::DateCompare(conman.GetConsume(i).GetDate,todate)<=0)
tempvec.push_back(conman.GetConsume(i));
}
/***********************************************************************
日期输入函数
***********************************************************************/
string CFormAppendMoney::InputDate()
{
//日期输入
string date;
CDateTime datetime;
date=datetime.GetDateTime().substr(0,10);
int x,y;
WhereXY(&x,&y);
do
{
GotoXY(x,y);
CMessageBox::Clear(x,10);
GetString(date,10);
int len=date.length();
if(date[len-1]==27)
break;
if(len==0)
{
CMessageBox::ShowMessage("Date cannot be null ! Input again.");
continue;
}
if(date[len-1]==27)
break;
if(CMyString::CheckDate(date))
break;
else
continue;
}while(1);
GotoXY(x,y);
CMessageBox::Clear(x,10);
return date;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -