I've got a little script that will create a text file from data that has been inputted into a spreadsheet. Basically, you click a button and it produces a text file.
This is work fine expect I need to have it create something that is a hex value. When trying to do this multiple ways, all I'm seeing in the text file in the number 1. I'd assume that if it were a non-displayable hex character it wouldn't just show a 1.
Hex values I need to generate are '01' '02' '03' '04' '08' '13' '14'.
Desired output format is:
$_0123456789 where _ will be one of the above hex characters.
Current section of code attempting to handle this is here:
variable1 is defined as string
variable2 has been defined as integer and as byte (neither worked as expected)
value_X are simple strings "XYZ"
[pre]
[/pre]
I've also tried to do variable2 = &H1 etc. without luck.
Thank you in advance for any help you can offer.
This is work fine expect I need to have it create something that is a hex value. When trying to do this multiple ways, all I'm seeing in the text file in the number 1. I'd assume that if it were a non-displayable hex character it wouldn't just show a 1.
Hex values I need to generate are '01' '02' '03' '04' '08' '13' '14'.
Desired output format is:
$_0123456789 where _ will be one of the above hex characters.
Current section of code attempting to handle this is here:
variable1 is defined as string
variable2 has been defined as integer and as byte (neither worked as expected)
value_X are simple strings "XYZ"
[pre]
Code:
Select Case variable1
Case value_1
variable2 = Hex(1)
Case value_2
variable2 = Hex(2)
Case value_3
variable2 = Hex(3)
Case value_4
variable2 = Hex(4)
Case value_5
variable2 = Hex(8)
Case value_6
variable2 = Hex(13)
Case value_7
variable2 = Hex(14)
End Select
I've also tried to do variable2 = &H1 etc. without luck.
Thank you in advance for any help you can offer.