Re: Losing Accuracy in reading numbers

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



AGP,

Simple search on Internet about accuracy and doubles. This is a dead horse.

Cor


"AGP" <sindizzy.pak@xxxxxxxxxxxx> schreef in bericht news:5ptuk.11294$L_.8281@xxxxxxxxxxxxxxxxxxxxxxx
I thought i had this down but i think i am missing something. i read in a
series of strings in CSV format that are actually numbers. i do something
like

Dim gVal as Double
Dim sData as String = "77.05788457660967"

gVal = Double.Parse(gArrCoords(0),
Globalization.NumberFormatInfo.InvariantInfo)
Debug.printline(gVal)

and this is what i get printed
77.057884576609666

This one seems to be small but i thought the double was supposed to hold the
exact number. I think the conversion has to do with the accuarcy built into
the format type but I cant figure out how to convert the exact number.
Suppose this was a scientific app that required extreme accuarcy in reading
the source data. How would i read it or assign it differently?

tia

AGP





.



Relevant Pages

  • Losing Accuracy in reading numbers
    ... series of strings in CSV format that are actually numbers. ... the format type but I cant figure out how to convert the exact number. ... Suppose this was a scientific app that required extreme accuarcy in reading ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Writing Oracle Output to a File
    ... I attempting to execute an Oracle query, and write the results to a ... file in CSV format. ... I get the first row of the query, ... try to convert the tuples into strings, but am not sure if that is the ...
    (comp.lang.python)
  • Re: Query
    ... I don't need an exact match, I can get that to work. ... >Microsoft Access MVP ... >>text strings on an incoming file and compare them to a ... For example, compare name ...
    (microsoft.public.access.queries)
  • Re: How to exclude a string using regexp pattern?
    ... exact output from the Unix grepping tool, ... lots of irrelevant strings ... That part of the regex will match everything up ...
    (comp.lang.java.programmer)
  • CVS file only inserts commas for 15 lines of spread
    ... I hava an user in Europe that is following the exact steps I am to ... covert a file to CSV format. ...
    (microsoft.public.excel)