Confused why bytes are being truncated
|
I have this program which ive been working on to convert Pronto codes to a form that the Sony AX series remotes understand, however i have a problem which i cant explain why it happens.
this is what im talking about
Private Sub nx_convert()
Text49.Text = Text53.Text
If Text50.Text = "12" Then a5 = "01"
If Text50.Text = "15" Then a5 = "02"
If Text50.Text = "20" Then a5 = "03"
Text57.Text = a5 & a6 & "0000" & a7 & "00000003"
End Sub
When the program is run the a5 should be 03 but it truncates the leading zero.
The other problem im having is hot to convert the contents of text 51,52,53 to a 2 byte hex value
here is a sample pronto code
0000 0066 0000 0015 0061 0018 0030 0018 0018 0018 0018 0018 0030 0018 0030 0018 0018 0018 0018 0018 0018 0018 0030 0018 0018 0018 0030 0018 0030 0018 0018 0018 0030 0018 0018 0018 0030 0018 0030 0018 0018 0018 0018 0018 0030 020b
|
Last edited by sila1999; 08-13-2006 at 07:52 AM.
Reason: added pronto code
|