IHaveRegistered
Knight
VB6 - Hex issues
Hey! I was wondering about code to convert hex into a digit... I've been trying, yet i've found no way to fix any digits like "G" and "M" and "$" and such... They cause the stuff to give an error.
Here's what i'm talking about... Text1 and Text2 are the text boxes.
Scenario 1:
-User imputs a HEX code (like FB34) into Text1
-I use command Text2.Text = Int(Text1.Text)
-Output should go into Text2...
-Say user 'messed up' and typed "GB34" into Text1...
-Program crashes...
Scenario 2:
-User imputs NUMBERS into Text1...
-Messes up, types something like 103Y
-Text2 is supposed to make that HEX... It's too stupid to do so...
-Tries to use command Text2.Text = Hex(Text1.TexT) and crashes...
I don't know how to remove that, i've tried this tutorial on removing certain characters from a string, but that didn't work :\
So, if anyone knows... then please aid! lol
-Aiden
Hey! I was wondering about code to convert hex into a digit... I've been trying, yet i've found no way to fix any digits like "G" and "M" and "$" and such... They cause the stuff to give an error.
Here's what i'm talking about... Text1 and Text2 are the text boxes.
Scenario 1:
-User imputs a HEX code (like FB34) into Text1
-I use command Text2.Text = Int(Text1.Text)
-Output should go into Text2...
-Say user 'messed up' and typed "GB34" into Text1...
-Program crashes...
Scenario 2:
-User imputs NUMBERS into Text1...
-Messes up, types something like 103Y
-Text2 is supposed to make that HEX... It's too stupid to do so...
-Tries to use command Text2.Text = Hex(Text1.TexT) and crashes...
I don't know how to remove that, i've tried this tutorial on removing certain characters from a string, but that didn't work :\
So, if anyone knows... then please aid! lol
-Aiden