Current location - Training Enrollment Network - Books and materials - Library lending system database
Library lending system database
cole datetime dt = cole datetime::get current time(); //Get the current time.

CString dtStr=dt。 Format ("%y//%m//%d% h:% m:% s"); //Convert to the string type of the style you want, and the time does not need to be removed.

bRecordset->; PutCollect("PlayTime ",_ variant _ t(dtStr)); //Convert to the data type accepted by the database and store it in the table.