Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Hexidecimal Word Proccessor

Posted on 1997-11-28
6
Medium Priority
?
174 Views
Last Modified: 2010-04-16
I would like to make a pascal program that will allow me
to type in phrases, sentences, etc, and it will display
its appropiate ASCII converted Hexidecimal output.
I would like this to work if i type in hexideciaml, for the
ascii output as well.  thanks
0
Comment
Question by:weinrj
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 2

Expert Comment

by:omsec
ID: 1216926

Hi ! To convert decimal numbers to hexadecimal strings isn't hard ! Check out the source procedure i wrote below. You may convert with it decimal numbers to any other mathematical systems like Hexadecimal, Binary or Octal etc.

Function DezConvert(Zahl : LongInt; Basis : Byte) : String;

Const
  HexStr      : String[16] = '0123456789ABCDEF';

Var
  HlpStr      : String;

Begin
   If Zahl = 0 Then
     HlpStr := '0'
   Else
     HlpStr := '';
   While Zahl <> 0 do
     Begin
       HlpStr := HexStr[(Zahl mod Basis) + 1] + HlpStr;
       Zahl   := Zahl div Basis;
     End;
   DezConvert := HlpStr;
End;

ZAHL is the number you wanna convert.
BASIS is the system's basis

to hex : BASIS is 16
to bin : BASIS is  2
to oct : BASIS is  8

Greets, Omsec
0
 
LVL 2

Expert Comment

by:omsec
ID: 1216927
That is only one way to do that... One of the fastest i know.
0
 

Author Comment

by:weinrj
ID: 1216928
thanks.  I figured what Zahl was since i know some german.
thank you for your help.  but would this work for

"Hello" into hexidecimal conversions?

thanks
0
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
LVL 2

Accepted Solution

by:
omsec earned 200 total points
ID: 1216929
Hexacedimal is a methamtic type. And 'HELLO' is a string. You cannot convert that "HELLO" in a number.
0
 
LVL 1

Expert Comment

by:FuzzyLogic
ID: 1216930
I think what weinrj wants is to convert the string "HELLO" into hexadeciaml form char by char. That means "48454C4C4F".
If this is what you want, you can easily modify omsec function to do that.

FuzzyLogic
0
 

Author Comment

by:weinrj
ID: 1216931
what fuzzylogic said is what i want.
please help me on this.
thanks


0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A walk-through example of how to obtain and apply new DID phone numbers to your cloud PBX enabled users that are configured in Office 365. Whether you have 1, 10 or 100+ users in your tenant, it's quite easy to get them phone-enabled and making/rece…
Are you looking for the options available for exporting EDB files to PST? You may be confused as they are different in different Exchange versions. Here, I will discuss some options available.
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question