Click here to Skip to main content
15,916,188 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Converting text to float (MFC) Pin
Member 166473326-Jan-05 9:05
Member 166473326-Jan-05 9:05 
GeneralRe: Converting text to float (MFC) Pin
Bob Ciora26-Jan-05 9:21
Bob Ciora26-Jan-05 9:21 
GeneralRe: Converting text to float (MFC) Pin
Member 166473326-Jan-05 9:31
Member 166473326-Jan-05 9:31 
GeneralRe: Converting text to float (MFC) Pin
David Crow26-Jan-05 9:59
David Crow26-Jan-05 9:59 
GeneralRe: Converting text to float (MFC) Pin
Member 166473326-Jan-05 10:06
Member 166473326-Jan-05 10:06 
GeneralRe: Converting text to float (MFC) Pin
David Crow26-Jan-05 10:11
David Crow26-Jan-05 10:11 
GeneralRe: Converting text to float (MFC) Pin
Bob Ciora26-Jan-05 10:43
Bob Ciora26-Jan-05 10:43 
GeneralRe: Converting text to float (MFC) Pin
David Crow26-Jan-05 8:53
David Crow26-Jan-05 8:53 
I'm not sure exactly what you are after here but converting text to double, as the subject implies, is as simple as the code snippet I provided earlier. The other code you have is definitely not necessary. You appear to be doing:

text --> double --> text

Is there a point to this exercise? If you are simply wanting to show in a message box what was typed, two lines of code will suffice:

GetDlgItemText(IDC_EDITBOX, txtEdit);
AfxMessageBox("Value is " + txtEdit);
If you need the value for calculation reasons, just call atof(txtEdit).


"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow


GeneralRe: Converting text to float (MFC) Pin
Tom Wright26-Jan-05 8:45
Tom Wright26-Jan-05 8:45 
GeneralRe: Converting text to float (MFC) Pin
Member 166473326-Jan-05 8:53
Member 166473326-Jan-05 8:53 
GeneralCDialog Question Pin
Anonymous26-Jan-05 5:53
Anonymous26-Jan-05 5:53 
GeneralRe: CDialog Question Pin
David Crow26-Jan-05 5:59
David Crow26-Jan-05 5:59 
GeneralRe: CDialog Question Pin
Anonymous26-Jan-05 6:26
Anonymous26-Jan-05 6:26 
GeneralRe: CDialog Question Pin
David Crow26-Jan-05 6:44
David Crow26-Jan-05 6:44 
GeneralRe: CDialog Question Pin
poiut26-Jan-05 8:36
poiut26-Jan-05 8:36 
GeneralRe: CDialog Question Pin
David Crow26-Jan-05 8:41
David Crow26-Jan-05 8:41 
GeneralRe: CDialog Question Pin
Blake Miller26-Jan-05 8:43
Blake Miller26-Jan-05 8:43 
GeneralRe: CDialog Question Pin
Anonymous26-Jan-05 9:20
Anonymous26-Jan-05 9:20 
GeneralRe: CDialog Question Pin
Blake Miller26-Jan-05 11:26
Blake Miller26-Jan-05 11:26 
GeneralRe: CDialog Question Pin
poiut26-Jan-05 9:37
poiut26-Jan-05 9:37 
Generaldsadas Pin
Anonymous26-Jan-05 5:08
Anonymous26-Jan-05 5:08 
GeneralDisplaying Tooltiptext -Problem Pin
Pazzuzu26-Jan-05 4:55
Pazzuzu26-Jan-05 4:55 
GeneralRe: Displaying Tooltiptext -Problem Pin
V.26-Jan-05 5:11
professionalV.26-Jan-05 5:11 
GeneralAccessing float from an Edit Box (MFC) Pin
Member 166473326-Jan-05 4:53
Member 166473326-Jan-05 4:53 
GeneralRe: Accessing float from an Edit Box (MFC) Pin
Chris Losinger26-Jan-05 5:32
professionalChris Losinger26-Jan-05 5:32 

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.