Advertisement
6_2008-2009 Math/ Dates #194810

Converting Decimal numbers to Binary

A function for converting decimal numbers to binary. Very fast.

AI

AI Summary: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.

Source Code
original-source
Private Sub Command1_Click()
DecValue = Val(Text1.Text)
BinValue = ""
Do
TempValue = DecValue Mod 2
  BinValue = CStr(TempValue) + BinValue
DecValue = DecValue \ 2
Loop Until DecValue = 0
'Print
'Print BinValue
Text2.Text = BinValue
End Sub

Upload
Original Comments (3)
Recovered from Wayback Machine