Click here to Skip to main content
15,911,503 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Format text in text file Pin
Xtorpia26-Apr-02 5:06
Xtorpia26-Apr-02 5:06 
GeneralDistributed compiling Pin
Braulio Dez26-Apr-02 1:31
Braulio Dez26-Apr-02 1:31 
GeneralRe: Distributed compiling Pin
26-Apr-02 1:44
suss26-Apr-02 1:44 
GeneralRe: Distributed compiling Pin
James R. Twine26-Apr-02 10:15
James R. Twine26-Apr-02 10:15 
GeneralRe: Distributed compiling Pin
Braulio Dez28-Apr-02 20:58
Braulio Dez28-Apr-02 20:58 
GeneralSYSTEMTIME - Difference Pin
Sameer Maggon25-Apr-02 23:36
Sameer Maggon25-Apr-02 23:36 
GeneralRe: SYSTEMTIME - Difference Pin
Niklas L26-Apr-02 0:22
Niklas L26-Apr-02 0:22 
GeneralRe: SYSTEMTIME - Difference Pin
Roger Allen26-Apr-02 1:53
Roger Allen26-Apr-02 1:53 
I have used 2 FILETIME objects like this before with the function:

FILETIME current_time ;
FILETIME start ;

::GetSystemTimeAsFileTime(&start) ;
Sleep(100) ;
::GetSystemTimeAsFileTime(¤t_time) ;
double elapsed = CalculateElapsedTime(&start, & current_time) ;

double CalculateElapsedTime(FILETIME *start, FILETIME *current)
{
	double	elapsed_time ;
	__int64	st ;
	__int64	ct ;
	__int32	*p ;

	p = (__int32*)&st ;
	*p++ = start->dwLowDateTime ;
	*p = start->dwHighDateTime ;
	//st = (start->dwHighDateTime << 32) + start->dwLowDateTime ;
	p = (__int32*)&ct ;
	*p++ = current->dwLowDateTime ;
	*p = current->dwHighDateTime ;
	//ct = (current->dwHighDateTime << 32) + current->dwLowDateTime ;
	elapsed_time = (double)(ct - st) ;
	elapsed_time /= 10000000.0 ;	// convert from 100ns intervals to seconds
	return elapsed_time ;
}



Roger Allen
Sonork 100.10016

If I had a quote, it would be a very good one.
GeneralRe: SYSTEMTIME - Difference Pin
Sameer Maggon26-Apr-02 2:09
Sameer Maggon26-Apr-02 2:09 
GeneralHook WH_CBT Pin
Sameer Maggon25-Apr-02 23:18
Sameer Maggon25-Apr-02 23:18 
GeneralRe: Hook WH_CBT Pin
Joaquín M López Muñoz25-Apr-02 23:31
Joaquín M López Muñoz25-Apr-02 23:31 
GeneralRe: Hook WH_CBT Pin
Sameer Maggon25-Apr-02 23:36
Sameer Maggon25-Apr-02 23:36 
GeneralRe: Hook WH_CBT Pin
Joaquín M López Muñoz25-Apr-02 23:42
Joaquín M López Muñoz25-Apr-02 23:42 
GeneralCHttpFile::Read() reads only 263 bytes! Pin
25-Apr-02 23:06
suss25-Apr-02 23:06 
GeneralRe: CHttpFile::Read() reads only 263 bytes! Pin
Philip Patrick26-Apr-02 0:52
professionalPhilip Patrick26-Apr-02 0:52 
GeneralRe: CHttpFile::Read() reads only 263 bytes! Pin
26-Apr-02 3:24
suss26-Apr-02 3:24 
GeneralRe: CHttpFile::Read() reads only 263 bytes! Pin
Joel Lucsy26-Apr-02 7:57
Joel Lucsy26-Apr-02 7:57 
GeneralRe: CHttpFile::Read() reads only 263 bytes! Pin
29-Apr-02 4:09
suss29-Apr-02 4:09 
Generalhelp! capturing mouse movements on pushbuttons Pin
Atilla Selem25-Apr-02 22:56
Atilla Selem25-Apr-02 22:56 
GeneralRe: help! capturing mouse movements on pushbuttons Pin
lucy26-Apr-02 3:02
lucy26-Apr-02 3:02 
GeneralRewrite 8-bit bmp image problem Pin
chen25-Apr-02 22:02
chen25-Apr-02 22:02 
GeneralRe: Rewrite 8-bit bmp image problem Pin
Joaquín M López Muñoz25-Apr-02 22:38
Joaquín M López Muñoz25-Apr-02 22:38 
GeneralRe: Rewrite 8-bit bmp image problem Pin
chen25-Apr-02 23:00
chen25-Apr-02 23:00 
Generalcopy selecting text from any applicaion to my application by hotkey Pin
25-Apr-02 21:59
suss25-Apr-02 21:59 
QuestionExtern function template !? Pin
Maxwell Chen25-Apr-02 20:31
Maxwell Chen25-Apr-02 20:31 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.