strings to floats

This is a discussion on strings to floats within the C++ Programming forums, part of the General Programming Boards category; Does anyone know how to convert a string to a float? I'm writing a program with strict error control and ...

  1. #1
    Registered User
    Join Date
    Apr 2002
    Posts
    47

    strings to floats

    Does anyone know how to convert a string to a float?

    I'm writing a program with strict error control and need an idea of how to prevent cin fail states when the end user types in a price.

    Thanks,
    bob2509

  2. #2
    Registered User Dual-Catfish's Avatar
    Join Date
    Sep 2001
    Posts
    802

  3. #3
    Registered User
    Join Date
    Apr 2002
    Posts
    47
    Thanks.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. A good way to convert strings to floats?
    By jcafaro10 in forum C++ Programming
    Replies: 4
    Last Post: 01-21-2009, 12:08 AM
  2. Strings Program
    By limergal in forum C++ Programming
    Replies: 4
    Last Post: 12-02-2006, 03:24 PM
  3. Programming using strings
    By jlu0418 in forum C++ Programming
    Replies: 5
    Last Post: 11-26-2006, 08:07 PM
  4. Reading strings input by the user...
    By Cmuppet in forum C Programming
    Replies: 13
    Last Post: 07-21-2004, 07:37 AM
  5. floats and strings
    By Stephen in forum C Programming
    Replies: 3
    Last Post: 11-07-2001, 02:43 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21