?
Solved

Doing Heavy Math

Posted on 1999-06-23
3
Medium Priority
?
233 Views
Last Modified: 2010-05-02
Is there a way to overload the math operations. In other words can I make the progra do all of it's math using floats or doubles or bytes? Is there a way to control that?
0
Comment
Question by:enoch100
3 Comments
 
LVL 12

Accepted Solution

by:
mark2150 earned 200 total points
ID: 1519284
Math follows the datatype of the vars. Certain math operators are type specific. Internally most all math is done in double precision reals.

M

0
 

Author Comment

by:enoch100
ID: 1519285
So how do I know? Where can I get that info?
0
 
LVL 18

Expert Comment

by:deighton
ID: 1519286

here's an example

dim i as long


i = 1000 * 100    'gives an errro

i = 1000 * 1000&



so suffix your numbers

10%    -    integer
1000&   -   long integer

3.14159265# - double


you can convert types using CLng, CInt,Cdbl etc.
0

Featured Post

Learn to develop an Android App

Want to increase your earning potential in 2018? Pad your resume with app building experience. Learn how with this hands-on course.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses

599 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question