字面意思就是日期和时间编辑控件,具体用法如下:
1 如何获取控件的数值
QDateTime dts;
dts=ui->控件名->dateTime(); //获取到了控件上的时间值
QSTring str1 = dts.totring("yyyy-MM-dd hh:mm:ss"); //转化成字符型
2转化成string类型作为参数
字面意思就是日期和时间编辑控件,具体用法如下:
1 如何获取控件的数值
QDateTime dts;
dts=ui->控件名->dateTime(); //获取到了控件上的时间值
QSTring str1 = dts.totring("yyyy-MM-dd hh:mm:ss"); //转化成字符型
2转化成string类型作为参数