Code:
Dim Number As Integer
HexTextBox.Text = If(Integer.TryParse(NumberTextBox.Text.Trim, Number) = True, Number.ToString("x"), "Cannot be converted to Hex")
Standard Numeric Format Strings
__________________
Currently using: VS 2005 & 2008 Pro w/sp1 on Win7 Ultimate x64.

There are 3 kinds of people in the world: Those who can count and those who can't.
4 out of 3 people have trouble with fractions.
Windows has a 64 bit GUI for a set of 32 bit extensions on a 16 bit shell for an 8 bit OS using a 4 bit kernel made by a 2 bit company that can't stand 1 bit of competition.
|