View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Ron Rosenfeld[_2_] Ron Rosenfeld[_2_] is offline
external usenet poster
 
Posts: 1,045
Default decimal to binary conversion

On Wed, 27 Nov 2013 15:36:41 -0500, GS wrote:

hello can you help fast ? tonight /
How do I convert a decimal number 23.125 to binary?


''''''''''''''''''
'by Rick Rothstein
''''''''''''''''''
Function DecToBin(ByVal DecimalIn As Variant, Optional NumberOfBits As
Variant) As String


When I try to implement this, it only converts the integer part, not the decimal part.

I usually use the BAseChange function in xNumbers (do a web search for this free add-in), for stuff like that.