Cobol Foro

Cobol Foro (https://www.cobolforo.es/index.php)
-   PowerCOBOL (ActiveX, v4 - v11) (https://www.cobolforo.es/forumdisplay.php?f=9)
-   -   [Sintaxis] Valores ASCII (https://www.cobolforo.es/showthread.php?t=86)

Recato53 2 de abril de 2015 19:14

Valores ASCII
 
Buenas tardes.

Como puedo saber el valor decimal de un ascii y el valor ascii de un decimal.

Ejemplo:
ASCII = A, Valor decimal 65
Valor decimal 90 , ASCII= Z

Muchas gracias

Kuk 2 de abril de 2015 21:15

1 Archivos Adjunto(s)
Aqui los tienes :cerv:

Recato53 3 de abril de 2015 10:24

No me he explicado bien.

Quiero obtener los valores ASCII con instrucciones Powercobol.

Ej: la variable VALOR-1= "A" -- mediante instrucciones PowerCobol -- VALOR-2 = "65"

Kuk 3 de abril de 2015 10:43

Lo haces con MOVE-s respectivos en la siguiente estructura:

Código COBOL:
  1. 01  VALOR-ASCII     PIC 9(4) BINARY.
  2. 01  FILLER REDEFINES VALOR-ASCII.
  3.     05  FILLER      PIC X.
  4.     05  VALOR-CHAR  PIC X.


La franja horaria es GMT +2. Ahora son las 14:01.

Powered by: vBulletin, Versión 3.8.7
Derechos de Autor ©2000 - 2026, Jelsoft Enterprises Ltd.