Click here to Skip to main content
15,918,742 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Virual memory Pin
Hamid_RT18-Sep-08 20:01
Hamid_RT18-Sep-08 20:01 
AnswerRe: Virual memory Pin
Naveen18-Sep-08 20:52
Naveen18-Sep-08 20:52 
QuestionVirtual memory Pin
jinijinu18-Sep-08 17:39
jinijinu18-Sep-08 17:39 
AnswerRe: Virtual memory Pin
Rane18-Sep-08 19:07
Rane18-Sep-08 19:07 
QuestionEdit mode problem Pin
followait18-Sep-08 16:46
followait18-Sep-08 16:46 
AnswerRe: Edit mode problem Pin
Malli_S18-Sep-08 20:19
Malli_S18-Sep-08 20:19 
GeneralRe: Edit mode problem Pin
followait18-Sep-08 23:31
followait18-Sep-08 23:31 
GeneralRe: Edit mode problem Pin
Malli_S19-Sep-08 1:24
Malli_S19-Sep-08 1:24 
GeneralRe: Edit mode problem Pin
followait19-Sep-08 1:30
followait19-Sep-08 1:30 
GeneralRe: Edit mode problem Pin
Malli_S19-Sep-08 1:41
Malli_S19-Sep-08 1:41 
GeneralRe: Edit mode problem Pin
followait19-Sep-08 2:12
followait19-Sep-08 2:12 
AnswerRe: Edit mode problem Pin
Mark Salsbery19-Sep-08 6:46
Mark Salsbery19-Sep-08 6:46 
GeneralRe: Edit mode problem [modified] Pin
followait19-Sep-08 14:14
followait19-Sep-08 14:14 
QuestionPrint after add view Pin
Max++18-Sep-08 15:46
Max++18-Sep-08 15:46 
AnswerRe: Print after add view [modified] Pin
followait18-Sep-08 16:52
followait18-Sep-08 16:52 
QuestionManifest File Pin
Bram van Kampen18-Sep-08 15:08
Bram van Kampen18-Sep-08 15:08 
QuestionMulti Threaded debug question Pin
monsieur_jj18-Sep-08 14:29
monsieur_jj18-Sep-08 14:29 
AnswerRe: Multi Threaded debug question Pin
Saurabh.Garg18-Sep-08 15:03
Saurabh.Garg18-Sep-08 15:03 
QuestionVisual Studio 6 - helpful debugger? Pin
charlieg18-Sep-08 12:18
charlieg18-Sep-08 12:18 
AnswerRe: Visual Studio 6 - helpful debugger? Pin
Mark Salsbery19-Sep-08 6:49
Mark Salsbery19-Sep-08 6:49 
GeneralRe: Visual Studio 6 - helpful debugger? Pin
charlieg21-Sep-08 2:54
charlieg21-Sep-08 2:54 
Questionatof() in Visual Studio 6 vs 2005 Pin
FoxholeWilly18-Sep-08 10:38
FoxholeWilly18-Sep-08 10:38 
AnswerRe: atof() in Visual Studio 6 vs 2005 Pin
Mark Salsbery18-Sep-08 10:48
Mark Salsbery18-Sep-08 10:48 
GeneralRe: atof() in Visual Studio 6 vs 2005 Pin
FoxholeWilly18-Sep-08 12:16
FoxholeWilly18-Sep-08 12:16 
GeneralRe: atof() in Visual Studio 6 vs 2005 Pin
Mark Salsbery19-Sep-08 5:03
Mark Salsbery19-Sep-08 5:03 
FoxholeWilly wrote:
Compiler did not like TCHAR


#include <tchar.h>


FoxholeWilly wrote:
When looking at atof() and _wtof() in the watch window, the results are both 409600.0000

The double variables both show 101523136.00000000 in the watch window.



That doesn't make sense. How do you watch the functions?

I fired up VS 2005 and wrote this:
#ifndef _WIN32_WINNT 
#define _WIN32_WINNT 0x0501
#endif						

#include <stdio.h>
#include <tchar.h>
#include <math.h>
#include <stdlib.h>


int _tmain(int argc, _TCHAR* argv[])
{
	// Non-Unicode
	char charbuffer[] = "409600.0000";
	double doublefromchar = atof(charbuffer);

	// Unicode
	wchar_t wcharbuffer[] = L"409600.0000";
	double doublefromwchar = _wtof(wcharbuffer);

	// Generic text
	TCHAR tcharbuffer[] = _T("409600.0000");
	double doublefromtchar = _tstof(tcharbuffer);

	return 0;
}

I can't reproduce anything you are seeing...you've got something
else going on you're not showing us.


Mark

Mark Salsbery
Microsoft MVP - Visual C++

Java | [Coffee]

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.