Convert binary into text/text into binary

Reply

Join Date: Jan 2006
Posts: 16
Reputation: Katrix36 is an unknown quantity at this point 
Solved Threads: 0
Katrix36 Katrix36 is offline Offline
Newbie Poster

Convert binary into text/text into binary

 
0
  #1
Apr 24th, 2006
Hey all,

Would anyone be able to help me out with some code to convert text into binary / binary into text?

Your help would be much appriated.

Katrix36
Reply With Quote Quick reply to this message  
Join Date: Dec 2004
Posts: 12
Reputation: nvanevski is an unknown quantity at this point 
Solved Threads: 1
nvanevski nvanevski is offline Offline
Newbie Poster

Re: Convert binary into text/text into binary

 
0
  #2
May 12th, 2006
It might seem strange to you, but text files are binary, too. It's the application that treats them differently. For example, if you change the extension from .txt to .bin, the application will not handle it the same.

If you are more precise in what you want to do, we might be able to help you better.
Reply With Quote Quick reply to this message  
Join Date: Jan 2006
Posts: 16
Reputation: Katrix36 is an unknown quantity at this point 
Solved Threads: 0
Katrix36 Katrix36 is offline Offline
Newbie Poster

Re: Convert binary into text/text into binary

 
0
  #3
May 13th, 2006
Originally Posted by nvanevski
It might seem strange to you, but text files are binary, too. It's the application that treats them differently. For example, if you change the extension from .txt to .bin, the application will not handle it the same.

If you are more precise in what you want to do, we might be able to help you better.
To be more precise, I'm wanting a program that I can type some text into a textbox or memo, and then it displays that text in binary in another textbox/memo.
Reply With Quote Quick reply to this message  
Join Date: Dec 2004
Posts: 12
Reputation: nvanevski is an unknown quantity at this point 
Solved Threads: 1
nvanevski nvanevski is offline Offline
Newbie Poster

Re: Convert binary into text/text into binary

 
0
  #4
May 13th, 2006
That should be pretty straightforward. On a click of a button, take the Text property into a String variable, then with one "for" loop walk the string, take every character, get the integer presentation using the Asc function, and display it in the other memo.
Reply With Quote Quick reply to this message  
Join Date: Jan 2006
Posts: 16
Reputation: Katrix36 is an unknown quantity at this point 
Solved Threads: 0
Katrix36 Katrix36 is offline Offline
Newbie Poster

Re: Convert binary into text/text into binary

 
0
  #5
May 13th, 2006
thank you for youe help
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Pascal and Delphi Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC