How would I go about converting string of binary data to hexidecimal data?
Re: binaryto hex
Loop through the string to convert each character to a byte. For example,
Dim I As Integer
For I = 1 to Len(Buffer)
Debug.Print Hex$(Asc(Mid$(Buffer, I, 1)))
Of course, all this does is to display the hex value. You would eliminate
the Hex$ function to simply use each value. If the data have some sort of
structure, you have to modify the routine to recognize that structure.
Richard Grier (Microsoft Visual Basic MVP)
Hard & Software
12962 West Louisiana Avenue
Lakewood, CO 80228
Author of Visual Basic Programmer's Guide to Serial Communications, 2nd
Edition ISBN 1-890422-25-8 (355 pages).
For information look on my homepage at http://www.hardandsoftware.net.
Use the Books link to order. For faster service contact the publisher at
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL