2.2.2 Cobol        
Hello world           
                                                                                                   
                                         
IDENTIFICATION DIVISION.
       PROGRAM ID.     HELLO.
       ENVIRONMENT DIVISION.
       DATA DIVISION.
       WORKING STORAGE SECTION.
01  PDFLIB PAGE SIZE CONSTANTS.
           05  PDFLIB A4 WIDTH         USAGE COMP 1 VALUE 5.95E+2.
           05  PDFLIB A4 HEIGHT        USAGE COMP 1 VALUE 8.42E+2.
       01  PDFLIB CALL AREA.
           05  P                       PIC S9(9) BINARY.
           05  RC                      PIC S9(9) BINARY.
           05  PDFLIB RETURN LONG      PIC S9(9) BINARY.
           05  PDFLIB RETURN CHAR      PIC X(64) VALUE SPACES.
           05  PDFLIB ERR STRING       PIC X(128).
       01  WS WORK FIELDS.
           05  WS INT                  PIC S9(9) BINARY.
           05  WS FONT                 PIC S9(9) BINARY.
           05  WS FLOAT                COMP 1.
           05  WS FLOAT2               COMP 1.
           05  WS STRING               PIC X(128).
           05  WS STRING2              PIC X(128).
           05  WS NULL                 PIC X(1) VALUE LOW VALUES.
       PROCEDURE DIVISION.
      * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
      *
PDF                  
*
      * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
           CALL "PDNEW" USING          P,
                                       RC.
      * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
      *
    
PDF          
*
      * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
           MOVE 0 TO WS INT.
           STRING Z HELLO.PDF 
                   DELIMITED BY SIZE INTO WS STRING.
           CALL "PDBEGDOC" USING       P,
                                       WS STRING,
                                       WS INT,
                                       WS NULL,
                                       PDFLIB RETURN LONG,
                                       RC.
           IF PDFLIB RETURN LONG =  1
               CALL "PDERRMSG" USING   P,
                                       PDFLIB ERR STRING,
                                       RC
               DISPLAY PDFLIB ERR STRING
2.2  Cobol                  
23






footer




 

 

 

 

 Home | About Us | Network | Services | Support | FAQ | Control Panel | Order Online | Sitemap | Contact

cgi web hosting

 

Our partners: PHP: Hypertext Preprocessor Best Web Hosting Java Web Hosting Inexpensive Web Hosting  Jsp Web Hosting

Cheapest Web Hosting Jsp Hosting Cheap Hosting

Visionwebhosting.net Business web hosting division of Web Design Plus. All rights reserved