Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
General
»
hex to dec (and vice versa) in Linux
Free Pascal
Website
Downloads
Wiki
Documentation
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Documentation (RTL/FCL/LCL)
Bugtracker
CCR Bugs
GIT
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
Forum Rules
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
Search
Advanced search
Recent
could Ardour's YTK be use...
by
fifr
[
Today
at 02:34:39 pm]
Getting results from sql ...
by
CraigC
[
Today
at 02:31:12 pm]
Questions about TFuncSeri...
by
hedgehog
[
Today
at 02:14:17 pm]
declaring Array
by
Thaddy
[
Today
at 01:24:11 pm]
Hello! Anything new?
by
marcov
[
Today
at 01:22:19 pm]
GTK3 : Icons have borders...
by
Schmitty2005
[
Today
at 01:02:16 pm]
Problem with drawing orde...
by
wp
[
Today
at 11:32:56 am]
TChart: Wrong default val...
by
wp
[
Today
at 11:30:54 am]
Text Fill (Memo)
by
paweld
[
Today
at 09:09:13 am]
Qt6/Wayland clipboard: pa...
by
AlexTP
[
Today
at 08:56:58 am]
Pocketbase
by
PierceNg
[
Today
at 06:29:04 am]
ADUG Symposium 2026
by
Mathias Burbach
[
Today
at 04:45:57 am]
Any way to "embed" Window...
by
jamie
[
Today
at 12:55:37 am]
CryptoLib4Pascal
by
Xor-el
[
Today
at 12:39:35 am]
CONCAT formula
by
veb86
[March 13, 2026, 05:20:42 pm]
DataPort StopBits and Flo...
by
Thaddy
[March 13, 2026, 02:14:16 pm]
Lazarus Bugfix Release 4....
by
JuhaManninen
[March 13, 2026, 10:05:03 am]
88 year D. Knuth changes ...
by
Thaddy
[March 13, 2026, 07:31:38 am]
interface and GUID someth...
by
egsuh
[March 13, 2026, 03:31:00 am]
CADSys4 3D.
by
maurog
[March 13, 2026, 01:00:05 am]
UOS - pre-compiled librar...
by
Fred vS
[March 13, 2026, 12:34:06 am]
Pipewire API
by
Fred vS
[March 12, 2026, 10:11:02 pm]
TSplitter color property ...
by
valdir.marcos
[March 12, 2026, 09:20:11 pm]
ShortStrings vs long stri...
by
valdir.marcos
[March 12, 2026, 08:55:02 pm]
LazPaint (alpha-blending,...
by
CM630
[March 12, 2026, 08:38:30 pm]
« previous
next »
Print
Pages: [
1
]
Author
Topic: hex to dec (and vice versa) in Linux (Read 3101 times)
Osvaldo Arruda
New Member
Posts: 27
hex to dec (and vice versa) in Linux
«
on:
October 18, 2012, 11:52:43 pm »
I need some function that converts hex to dec and vice versa operating only strings. For use on Linux.
Thanks all
Logged
taazz
Hero Member
Posts: 5368
Re: hex to dec (and vice versa) in Linux
«
Reply #1 on:
October 18, 2012, 11:57:08 pm »
inttostr, inttohex and strtoint do exactly that. Just make sure that the hex number has a dollar sign in front of the value eg $AD instead of AD and strtoint will convert that to an integer.
Logged
Good judgement is the result of experience … Experience is the result of bad judgement.
OS : Windows 7 64 bit
Laz: Lazarus 1.4.4 FPC 2.6.4 i386-win32-win32/win64
typo
Hero Member
Posts: 3051
Re: hex to dec (and vice versa) in Linux
«
Reply #2 on:
October 19, 2012, 01:16:27 am »
There are also Dec2Num and Num2Dec, I can't remember on which unit they are declared.
Logged
LazarusBrasil.Org
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
General
»
hex to dec (and vice versa) in Linux
TinyPortal
© 2005-2018