I have a question.
I want create MIDI file that is binary file with Hexadecimal Number. My soft method has all function with using decimal number property. I need convert Numbers to Hexadecimal Number.
I get to know &h and Hex method. But Hex method is result to return strings. Then I try Val or CDbl method, but this result is decimal number only maybe.
i.e
Dim theNo As Integer
theNo=Val("&h"+ Hex(123)) // this result is 291 as decimal
How to change decimal number converts Hexadecimal Number?
Do I need original method create?
Please teach me.
Thank you replay. I realize that. Integer property is able to have hexadecimal. But I want converting. I use set &h number to integer. Just I want 100 to Convert to &h64 or so.
Hexadecimal , Octal or anything else is a REPRESENTATION of a NUMBER, nothing more
100 in decimal is &H64 displayed as Hexadecimal and &O144 displayed in Octal… but it is the SAME numeric value, and that is all a computer cares about.
Also be aware if you start representing numbers >255 that you need to consider the environment you are in. is it LITTLE ENDIAN? or BIG ENDIAN? as this affects the ORDER of the bytes