Search content:

 

Personal Menu
Username:
Password:
Save password

Become a member

Forgot Password?

 

Don't miss these
Sending a e-mail with attachment using CDO and VbScriptXtra
SmartOLE Xtra
Vector Shape - Create Frame
File open/save dialog
More encryption
XmySQL
Animation on MouseUp
ActiveX Web controler
Sound not playing
Timehouse Speech Xtra
MediaMacros Xtras Mall
 

 

 

Behavior Convert between bases-Integer to String

Added on 6/27/2000

 

Compatibilities:
D7 D8 Mac PC Script Shockwave

Rating:

Author: JoergSeibert

Converts an integer to a string based on a set base

--Based on scripts by Kevan Dettelbach and Chuck Neal

--Convert a positive integer in a String based on base
-- for int-to-hex call ConvBase(nConv, 16)
-- for int-to-bit call ConvBase(nConv, 2)
on convBase nConvNum, nBase
  if (nBase > 1 and nBase < 17) and (nConvNum > -1) then
    baseNums = ["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F"]
    szConverted = ""
    repeat while nConvNum
      nMod = nConvNum mod nBase
      szConverted = baseNums[nMod + 1] & szConverted
      nConvNum = nConvNum / nBase
    end repeat
    return szConverted
  else
    return VOID
  end if
end

 


Upload Provided by ABCUpload ASP

Contact

MMI
22 West Court Sq
Suite 2C
Newnan, GA 30263
USA

Fax - (206) 339-5833

Send e-mail