473,406 Members | 2,633 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Hex to int conversion support

Newbie trying to play around with forms creating a int to hex converter.
Does the framework have a conversion class? I can't believe that yet
another needs to be created.

Thanks for the feedback
Ron
Jul 21 '05 #1
1 1319
R Lee <W@W.W> wrote:
Newbie trying to play around with forms creating a int to hex converter.
Does the framework have a conversion class? I can't believe that yet
another needs to be created.


Just use the appropriate format specifier, x or X:

int i = 123;
string s = i.ToString("x");

s is now "7b"

See also Convert.ToString(int, int).

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Jul 21 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Chris Brown | last post by:
Hello, I work for a company that sells a product with a VFP frontend/MSSQL backend, and we have become aware for many reasons the we need to switch over to ..net. The problem is that our...
1
by: Kel Good | last post by:
Hello, I recently created a structure in C# that offers several implicit conversion, hoping I could then reference the C# project from a VB.Net project, and use this object in VB.Net. It does...
7
by: Sanjay Kedare | last post by:
Hi, I am evaluating various alternatives of converting Delphi (Ver 4.0) screens to C# screens. Are there any tools available for such conversion? if yes how much conversion do they achieve? The...
18
by: Ger | last post by:
I have not been able to find a simple, straight forward Unicode to ASCII string conversion function in VB.Net. Is that because such a function does not exists or do I overlook it? I found...
0
by: Joergen Bech | last post by:
Help! Looking for a .Net-kompatible component for converting between HTML and RTF (both ways). Asked this question a few days ago and received this link:...
4
by: Chris Brown | last post by:
Hello, I work for a company that sells a product with a VFP frontend/MSSQL backend, and we have become aware for many reasons the we need to switch over to ..net. The problem is that our...
1
by: Philip Bondi | last post by:
Hello to all SQL Server junkies who work with non-English characters: For people running scripts from the command line using ANSI files with special characters, it is very important to use isql...
0
by: Lou Evart | last post by:
DOCUMENT CONVERSION SERVICES Softline International (SII) operates one of the industry's largest document and data conversion service bureaus. In the past year, SII converted over a million...
0
by: maheshmohta | last post by:
Background Often while remodeling legacy application, one of the important tasks for the architects is to have an optimum usage of storage capabilities of database. Most of the legacy applications...
4
by: =?Utf-8?B?c2lwcHl1Y29ubg==?= | last post by:
Hi I am converting a VS2005 Solution to VS2008 Solution and all went well I checked the Solution file (sln) and Project file (csproj) into SVN - I checkout the solution from SVN and it want to ...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.