1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
|
#include <vcl.h>
#pragma hdrstop
#include"MMSystem.h"
#include"Main.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm140 *Form140;
//---------------------------------------------------------------------------
__fastcall TForm140::TForm140(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TForm140::Button1Click(TObject *Sender)
{
TDateTime Start =Now();
PlaySoundA("SYSTEMSTART", 0, SND_ASYNC);
TDateTime Stop =Now();
StatusBar1->Panels->operator[](1)->Text=FormatDateTime(L"hh:mm:ss.zzz",Stop-Start); // 3 ms sur ma vieille machine
}
//--------------------------------------------------------------------------- |
Partager