View previous topic :: View next topic
|
Author |
Message |
stalin.i@gmail.com
New User
Joined: 18 Apr 2005 Posts: 8 Location: chennai
|
|
|
|
Can any one coded direct ASCII to COBOL conversion routines.
I prefer to do this using COBOL only. Please explain the logic briefly.
If you have assembler code for direct HEX to ASCII conversion. Please make it available to me.
Cheers, |
|
Back to top |
|
|
dneufarth
Active User
Joined: 27 Apr 2005 Posts: 419 Location: Inside the SPEW (Southwest Ohio, USA)
|
|
|
|
do you mean EBCDIC to ASCII? |
|
Back to top |
|
|
stalin.i@gmail.com
New User
Joined: 18 Apr 2005 Posts: 8 Location: chennai
|
|
|
|
no Dave. I want to convert HEX to ASCII conversion using COBOL or ASSEMBLER. I will be very happy if you can give me the logic or code or Both.
Thanks for your response. |
|
Back to top |
|
|
dneufarth
Active User
Joined: 27 Apr 2005 Posts: 419 Location: Inside the SPEW (Southwest Ohio, USA)
|
|
|
|
I'm confused; give us an example.
x'30' is 0 in ascii, so how would you expect to convert it?
x'F0' (0 IN EBCDIC) would become x'30' (0 in ASCII) |
|
Back to top |
|
|
stalin.i@gmail.com
New User
Joined: 18 Apr 2005 Posts: 8 Location: chennai
|
|
|
|
input in hex "41414141'
output in ebcedic "AAAA"
I want to convert any given HEX value to equivalent EBCEDIC value |
|
Back to top |
|
|
stalin.i@gmail.com
New User
Joined: 18 Apr 2005 Posts: 8 Location: chennai
|
|
|
|
Sorry Dave, I am little confused now. I will post a clear example later. |
|
Back to top |
|
|
dneufarth
Active User
Joined: 27 Apr 2005 Posts: 419 Location: Inside the SPEW (Southwest Ohio, USA)
|
|
Back to top |
|
|
dneufarth
Active User
Joined: 27 Apr 2005 Posts: 419 Location: Inside the SPEW (Southwest Ohio, USA)
|
|
Back to top |
|
|
stalin.i@gmail.com
New User
Joined: 18 Apr 2005 Posts: 8 Location: chennai
|
|
|
|
Dave,
I used a existing assembler routines to do the job. Its works well. Thanks for all your sugessions.
I do have the EBCEDIC-ASCII table with me. I did not go for the inspect method because some valid HEX values do not have a equivalent EBCEDIC values.
Thanks again. |
|
Back to top |
|
|
mmwife
Super Moderator
Joined: 30 May 2003 Posts: 1592
|
|
|
|
P.S. There are no invalid HEX values. |
|
Back to top |
|
|
|