Solved

easy point

Posted on 1998-11-08
1
130 Views
Last Modified: 2010-04-30
In pascal or c, there is a function named 'rem' and 'mod' which return the reminder of the division. Like

         a = 5 rem 2;

then  1 will be stored into a.

         a = 17 rem 3;

then 2 will be stored into a.

Could I get this rem and mod function in vb.
If yes, how, I would like an example.
If no, how can I build this function, I would like a complete code.


Thank a lot.  
0
Comment
Question by:math253
1 Comment
 

Accepted Solution

by:
thunderbug110898 earned 200 total points
ID: 1443871
in VB:

Dim x As Integer

x = 10 mod 2

MsgBox x  ' this will display 0

x = 10 mod 3

MsgBox x ' this will display 1

0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
how to open Waze.com/livemap from address saved in DB? 26 213
MS SQL store procedure to calculate and return result 6 63
Problem to With line 4 63
Problem to line 23 55
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
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…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

821 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