DWUTKA at marlow.com
DWUTKA at marlow.com
Tue May 4 11:13:02 CDT 2004
Wow, a topic we can all agree on! <grin> Drew -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of John W. Colby Sent: Tuesday, May 04, 2004 11:04 AM To: Access Developers discussion and problem solving Subject: RE: [AccessD] Early Friday Untip Which just goes to show that it is important to understand what datatypes are for, how they work with the various math and logical operations, and what the specific variable is intended to do. If a float was the only datatype ever needed, it would be the only one available! John W. Colby www.ColbyConsulting.com -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Charlotte Foust Sent: Tuesday, May 04, 2004 11:32 AM To: Access Developers discussion and problem solving Subject: RE: [AccessD] Early Friday Untip Well Val() is officially included for backward compatibility (I guess they never mentioned that to the VB team <g>), and a lot of people simply don't understand the issues of floating point errors. They seem to be under the impressions that you're safe if you stick to adding or subtracting. If you want to add another omission, CCur(). Charlotte Foust -----Original Message----- From: Gustav Brock [mailto:gustav at cactus.dk] Sent: Monday, May 03, 2004 11:22 PM To: Access Developers discussion and problem solving Subject: [AccessD] Early Friday Untip Hi all Just noticed this "untip" from Element K Journals". Comments should not be necessary, but where did Val() and CLng() go? Why not let a programmer proofread such tips? <quote> Beware of CInt; use CDbl instead (VB 6.0) If you have any program that converts string values to numbers, you'll want to steer clear of the CInt function and use CDbl instead. The problem with CInt is that it only accepts numbers up to 32767. You might say today, "My number will never get that large." However, later on down the line, it might. Unfortunately, by that time, your code may be riddled with hundreds of CInt time bombs waiting to blow up, displaying the dreaded Overflow error. Using the CDbl function is no different from using CInt. The syntax is: CDBl(numericstring) CDbl returns the same value as CInt and it accepts num-bers up to 1.7976931348623158E+308. </quote> /gustav -- _______________________________________________ AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- _______________________________________________ AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- _______________________________________________ AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com