+ Reply to Thread
Results 1 to 5 of 5

Mod Function

Hybrid View

  1. #1
    Registered User
    Join Date
    07-28-2007
    Posts
    2

    Mod Function

    Friends,

    how can i do this in excel 2002?
    mod(1234567890123,97)

    thanks

  2. #2
    Forum Contributor
    Join Date
    12-12-2005
    Posts
    667
    You have to recompose the formula:
    a = 1234567890123# / 97# - (Int(1234567890123# / 97#))
    MsgBox a * 97
    Best regards,

    Ray

  3. #3
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,645
    In a formula:

    =(1234567890123/97 - INT(1234567890123/97))*97

    Though you won't get an exact result due to floating point issues.

  4. #4
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,736
    Instead of

    =MOD(A1,B1)

    try

    =A1-FLOOR(A1,B1)

    assumes A1 & B1 are positive numbers

  5. #5
    Registered User
    Join Date
    07-28-2007
    Posts
    2
    thanks daddylonglegs

    its working fine for 13 digits....but i need it for maximum 24 digits

    for example.....

    mod(95000000922019182020281000,97)=24

    but in excel im getting the value as 0
    also when i type the 24 digits its show like ..... #NUM!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1