[thelist] ASP Addition question

Beach Computers Web Hosting Groups at Beachcomp.com
Sun Jan 14 22:57:06 CST 2007


Ok, all is not well.
It's rounding the result value.
Eg: 14.95+15.00=30

Any ideas?

<%=CInt(Plans2.Fields.Item("PromoSetupfee").Value)+CInt(Plans2.Fields.Item("
PromoMonthlyPrice").Value)%>

 
Dave
 
 -----------------------------------
|Beach Computers                    |
|Affordable Hosting Solutions       |
|http://www.beachcomp.com           |
 ===================================
|Cheap Domain Warehouse             |
|Get Your Own Dot!                  |
|http://www.cheapdomainwarehouse.com|
 ---------------------------------- 

------------------------------------
Disclaimer and confidentiality note:

The contents of this communication are intended/meant only for addressee(s)
and may contain information that is privileged or otherwise confidential.
If you are not the intended recipient you are hereby notified that any
disclosure, copying, distribution or taking any action in reliance on the
contents of this information is strictly prohibited and may be unlawful.
The contents of this e-mail shall not be forwarded to any third party. If
you have received this electronic mail transmission in error, please delete
it from your system without copying or forwarding it, and notify the sender
of the error by reply email, so that the sender's address records
can be corrected.
Views and opinions are solely those of the sender unless clearly indicated
as being that of Beach Computers or any of it's affiliated companies.
Beach Computers cannot assure that the integrity of this communication has
been maintained or that it is free of errors, virus, interception or
interference.

-----Original Message-----
From: thelist-bounces at lists.evolt.org
[mailto:thelist-bounces at lists.evolt.org] On Behalf Of Beach Computers Web
Hosting
Sent: Sunday, January 14, 2007 7:03 PM
To: thelist at lists.evolt.org
Subject: Re: [thelist] ASP Addition question

Thanks much folks.

 
Dave
 
 -----------------------------------
|Beach Computers                    |
|Affordable Hosting Solutions       |
|http://www.beachcomp.com           |
 ===================================
|Cheap Domain Warehouse             |
|Get Your Own Dot!                  |
|http://www.cheapdomainwarehouse.com|
 ---------------------------------- 

------------------------------------
Disclaimer and confidentiality note:

The contents of this communication are intended/meant only for addressee(s)
and may contain information that is privileged or otherwise confidential.
If you are not the intended recipient you are hereby notified that any
disclosure, copying, distribution or taking any action in reliance on the
contents of this information is strictly prohibited and may be unlawful.
The contents of this e-mail shall not be forwarded to any third party. If
you have received this electronic mail transmission in error, please delete
it from your system without copying or forwarding it, and notify the sender
of the error by reply email, so that the sender's address records
can be corrected.
Views and opinions are solely those of the sender unless clearly indicated
as being that of Beach Computers or any of it's affiliated companies.
Beach Computers cannot assure that the integrity of this communication has
been maintained or that it is free of errors, virus, interception or
interference.

-----Original Message-----
From: thelist-bounces at lists.evolt.org
[mailto:thelist-bounces at lists.evolt.org] On Behalf Of Taurus James
Sent: Sunday, January 14, 2007 1:26 PM
To: info at thesitedoctor.co.uk; thelist at lists.evolt.org
Subject: Re: [thelist] ASP Addition question

ALso, use "IsNumeric" function before trying to cast to Integer:

if IsNumeric(Plans2.Fields.Item("Setupfee").Value) AND
IsNumeric(Plans2.Fields.Item("Setupfee").Value) then

     CInt(Plans2.Fields.Item("Setupfee").Value) +
CInt(Plans3.Fields.Item("Setupfee").Value)

else

     ' Decide what you want to do if either of the values from
the database is corrupted or not returned...

end if

- Taurus


--- Tim Gaunt <info at thesitedoctor.co.uk> wrote:

> Try:
> 
> <%= CInt(Plans2.Fields.Item("Setupfee").Value)+
> CInt(Plans3.Fields.Item("Setupfee").Va
> lue)%>
> 
> (Only if it's an int, otherwise cast accordingly)
> 
> Tim
> 
> -- 
> 
> * * Please support the community that supports you.  * *
> http://evolt.org/help_support_evolt/
> 
> For unsubscribe and other options, including the Tip Harvester
> 
> and archives of thelist go to: http://lists.evolt.org 
> Workers of the Web, evolt ! 
> 



 
____________________________________________________________________________
________
Sucker-punch spam with award-winning protection. 
Try the free Yahoo! Mail Beta.
http://advision.webevents.yahoo.com/mailbeta/features_spam.html
-- 

* * Please support the community that supports you.  * *
http://evolt.org/help_support_evolt/

For unsubscribe and other options, including the Tip Harvester 
and archives of thelist go to: http://lists.evolt.org 
Workers of the Web, evolt ! 



-- 

* * Please support the community that supports you.  * *
http://evolt.org/help_support_evolt/

For unsubscribe and other options, including the Tip Harvester 
and archives of thelist go to: http://lists.evolt.org 
Workers of the Web, evolt ! 






More information about the thelist mailing list