You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -370,238 +370,181 @@ Three ‘Enterprise COBOL for z/OS” manuals are referenced throughout the chap
370
370
371
371
## Lab
372
372
373
-
In this lab exercise, you will connect to an IBM Z system, view a simple COBOL hello world program in VSCode, submit JCL to compile the COBOL program, and view the output. Refer to "Installation of VSCode and extensions" to configure VSCode if you have not already done so. You can either use Z Open Editor and Zowe Explorer, or Code4z.
373
+
In this lab exercise, you will connect to an IBM Z system, view a simple COBOL hello world program in VSCode, submit JCL to compile the COBOL program, and view the output. Refer to "Installation of VSCode and extensions" to configure VSCode if you have not already done so. You can either use IBM Z Open Editor and Zowe Explorer, or Code4z.
374
374
375
-
1. The lab assumes installation of VSCode with either Z Open Editor and Zowe Explorer extensions, as shown in Figure 2a, or the Code4z extension pack, as shown in Figure 2b.
375
+
1. The lab assumes installation of VSCode with either IBM Z Open Editor and Zowe Explorer extensions, as shown in Figure 2a, or the Code4z extension pack, as shown in Figure 2b.
376
376
377
-
Click the **Extensions** icon. If you installed Z Open Editor and Zowe Explorer, the list should include:
377
+
Click the **Extensions** icon. If you installed IBM Z Open Editor and Zowe Explorer, the list should include:
378
378
379
379
1. IBM Z Open Editor
380
380
2. Zowe Explorer
381
381
382
382

383
383
384
-
*Figure 2a. The Z Open Editor and Zowe Explorer VSCode extensions*
384
+
*Figure 2a. The IBM Z Open Editor and Zowe Explorer VSCode extensions*
385
385
386
-
If you installed Code4z, the list should include:
387
-
388
-
1. COBOL Language Support
389
-
2. Zowe Explorer
390
-
3. Explorer for Endevor
391
-
4. HLASM Language Support
392
-
5. Debugger for Mainframe
393
-
6. COBOL Control Flow
386
+
If you installed Code4z, the list should include:
394
387
388
+
1. COBOL Language Support
389
+
2. Zowe Explorer
390
+
3. Explorer for Endevor
391
+
4. HLASM Language Support
392
+
5. Debugger for Mainframe
393
+
6. COBOL Control Flow
395
394
396
395
In these exercises, you will only use the COBOL Language Support and Zowe Explorer extensions.
397
396
398
397

399
398
400
-
*Figure 2b. The Code4z package of VS Code extensions.*
399
+
*Figure 2b. The Code4z package of VSCode extensions.*
401
400
402
401
**Note:** If your list contains both Z Open Editor and COBOL Language Support, disable one of them, by clicking on the **cog** icon next to the extension in the extensions list, and selecting **disable**.
403
402
404
-
2. Click the Zowe Explorer icon as shown in Figure 3.
403
+
2. Click the Zowe Explorer icon as shown in Figure 3. Zowe Explorer can list Data Sets, Unix System Services (USS) files, and Jobs output.
405
404
406
405

407
406
408
407
*Figure 3. Zowe Explorer Zowe Explorer icon*
409
408
410
-
3. Zowe Explorer can list Data Sets, Unix System Services (USS) files, and Jobs output as shown in Figure 4. + will appear when hovering to the far right on the DATA SETS line. Click the + to define a VSCode profile.
411
-
412
-

413
-
414
-
*Figure 4. Zowe Explorer*
415
-
416
-
4. A box appears to define a new profile. Click + to the left of Create a New Connection to z/OS as shown in Figure 5.
417
-
418
-

419
-
420
-
*Figure 5. Create a new connection to z/OS*
421
-
422
-
423
-
5. Select a name to enter, then enter. Figure 6. used `LearnCOBOL` as the selected connection name.
424
-
425
-

426
-
427
-
*Figure 6. Set connection name*
428
-
429
-
430
-
6. VSCode prompts for z/OSMF URL and port as shown in Figure 7. The z/OSMF URL and port will normally be provided by the z/OS System Administrator.
409
+
3. In order to connect to the lab system, get your team configuration zip file and extract it.
431
410
432
-

411
+

433
412
434
-
*Figure 7. z/OSMF URL*
413
+
*Figure 4. Extract the ZIP file*
435
414
436
-
7. A sample z/OSMF URL and port is entered as shown in Figure 8.
415
+
4. Open the extracted folder. You will find the two configuration files as shown in Figure 5.
437
416
438
-

417
+

439
418
440
-
*Figure 8. Specified z/OSMF URL*
419
+
*Figure 5. Inside the Team configuration file*
441
420
442
-
8. The connection prompts for Username as shown in Figure 9.
421
+
5. Now back on your VSCode window, select the Explorer tab and press the "Open folder" button in the left bar.
443
422
444
-

445
-
446
-
*Figure 9. User name prompt*
423
+

447
424
448
-
9.**Please enter the username assigned to you! Do not use the sample username of Z99998.** A sample username, is entered as shown in Figure 10. The ID is assigned by the System Administrator.
425
+
*Figure 6. Click the open folder button*
449
426
450
-

427
+
6. A pop-up window would show up, select the folder containing the team configuration files.
451
428
452
-
*Figure 10. Specified user name*
429
+

453
430
431
+
*Figure 7. Select the team Configuration folder*
454
432
455
-
10. The connection prompts for the password as shown in Figure 11.
433
+
7. Your connection should be added automatically to the Data Sets list as shown in Figure 8a.
456
434
457
-

435
+

458
436
459
-
*Figure 11. Password prompt*
460
-
461
-
11. Enter the password as shown in Figure 12.
462
-
463
-

437
+
*Figure 8a. LearnCOBOL Connection*
464
438
465
-
*Figure 12. Specified password*
439
+
If the connection does not appear, hover to the far right of the Data Sets line and press the + icon. Afterwards, select the **LearnCOBOL** connection as shown in Figure 8b.
466
440
467
-
12. Select **False - Accept connections with self-signed certificates** to authorize workstation connection as shown in Figure 13.
*Figure 13. Accept connections with self-signed certifications*
445
+
8. Press the LearnCOBOL connection.
472
446
473
-
13. Press **Enter** for the rest of the prompts to choose the default values
447
+

474
448
475
-

449
+
*Figure 9. Pressing the LearnCOBOL Connection*
476
450
477
-

478
-
479
-

480
-
481
-

451
+
9. The connection prompts for a username as shown in Figure 10.
482
452
453
+

483
454
455
+
*Figure 10. User name prompt*
484
456
485
-
14. Your connection will be added automatically to the **DATASET** list under **Favorites**as shown in Figure 14.
457
+
10.**Please enter the username assigned to you! Do not use the sample username of Z99998.** A sample username, is entered as shown in Figure 11. The ID is assigned by the System Administrator.
486
458
487
-

459
+

488
460
489
-
*Figure 14. LEARNCOBOL connection*
461
+
*Figure 11. Specified user name*
490
462
491
-
- Note : *if you click on the + to the far right on the Data Sets selection, another prompt to Create a New Connection to z/OS will appear.*
492
-
- any other connections you have will be listed as shown in Figure 15.
493
-
494
-

495
-
496
-
*Figure 15. connections list*
463
+
11. The connection prompts for a password as shown in Figure 12.
497
464
498
-
465
+

499
466
500
-
15. Expansion of LEARNCOBOL reads “Use the search button to display datasets”. Click the search button as shown in Figure 16.
467
+
*Figure 12. Password prompt*
501
468
502
-

469
+
12. Enter your assigned password as shown in Figure 13.
503
470
504
-
*Figure 16. Search button*
471
+

505
472
506
-
473
+
*Figure 13. Specified password*
507
474
508
-
16. A prompt to "Select a filter" appears for your username. Select the + to "Create a new filter" as shown in Figure 17.
475
+
13. Expanding LearnCOBOL shows “Use the search button to display datasets”. Click the magnifying glass icon as shown in Figure 14.
509
476
510
477

511
478
512
-
*Figure 17. Select a filter*
513
-
514
-
479
+
*Figure 14. Magnifying glass icon to set a filter*
515
480
516
-
17.A prompt appears to enter the filter name to be searched as shown in Figure 18.
481
+
14.A prompt to "Search Data Sets" will appear as shown in Figure 15.
517
482
518
483

519
484
520
-
*Figure 18. Filter name to be searched*
485
+
*Figure 15. Filter name to be searched*
521
486
522
-
523
-
524
-
18. Each user has a high-level qualifier that is the same as their username. Therefore, enter your assigned username as the search criteria as shown in Figure 19. **Please use your username, not Z99998!**
487
+
15. Each user has a high-level qualifier that is the same as their username. Therefore, enter your assigned username as the search criteria as shown in Figure 16. **Please enter the username assigned to you! Do not use the sample username of Z99998.**
525
488
526
489

527
490
528
-
*Figure 19. Entered filter name*
491
+
*Figure 16. Entered filter name*
529
492
530
-
531
-
532
-
19. A list of data set names beginning with your username from z/OS Connection LEARNCOBOL appears as shown in Figure 20.
493
+
16. A list of data set names beginning with your username will appear as shown in Figure 17.
533
494
534
495

535
496
536
-
*Figure 20. Filtered data set names*
537
-
538
-
497
+
*Figure 17. Filtered data set names*
539
498
540
-
20.Expand **`<USERNAME>.CBL`** to view COBOL source members, then select member **HELLO** to see a simple COBOL ‘Hello World!’ program as shown in Figure 21.
499
+
17.Expand **`<USERNAME>.CBL`** to view COBOL source members, then select member **HELLO** to see a simple COBOL ‘Hello World!’ program as shown in Figure 18.
541
500
542
501

543
502
544
-
*Figure 21. `<USERNAME>.CBL`*
503
+
*Figure 18. `<USERNAME>.CBL`*
545
504
546
-
547
-
548
-
21. Expand **`<USERNAME>.JCL`** to view JCL and select member HELLO which is the JCL to compile and execute simple ‘Hello World!’ COBOL source code as shown in Figure 22.
505
+
18. Expand **`<USERNAME>.JCL`** to view JCL and select member HELLO which is the JCL to compile and execute simple ‘Hello World!’ COBOL source code as shown in Figure 19.
549
506
550
507

551
508
552
-
*Figure 22. `<USERNAME>.JCL`*
553
-
554
-
509
+
*Figure 19. `<USERNAME>.JCL`*
555
510
556
-
22. Right-click on JCL member **HELLO**. A section box appears. Select **Submit Job** for the system to process HELLO JCL as shown in Figure 23. The submitted JCL job compiles the COBOL HELLO source code, then executes the COBOL HELLO program.
511
+
19. Right-click on JCL member **HELLO**. A section box appears. Select **Submit Job** for the system to process HELLO JCL as shown in Figure 20. The submitted JCL job compiles the COBOL HELLO source code, then executes the COBOL HELLO program.
557
512
558
513

559
514
560
-
*Figure 23. Submit Job*
561
-
562
-
515
+
*Figure 20. Submit Job*
563
516
564
-
23. Observe the ‘Jobs’ section in Zowe Explorer as shown in Figure 24.
517
+
20. Observe the ‘Jobs’ section in Zowe Explorer as shown in Figure 21.
565
518
566
519

567
520
568
-
*Figure 24. JOBS section*
521
+
*Figure 21. JOBS section*
569
522
570
-
571
-
572
-
24. Again, click on the + to the far right on the Jobs selection. The result is another prompt to ‘Create new’. Select **LearnCOBOL** from the list as shown in Figure 25.
523
+
21. Again, click on the + to the far right on the Jobs selection. The result is another prompt to ‘Create new’. Select **LearnCOBOL** from the list as shown in Figure 22.
573
524
574
525

575
526
576
-
*Figure 25. + Select LEARNCOBOL connection*
577
-
578
-
527
+
*Figure 22. Select LearnCOBOL connection*
579
528
580
-
25. As a result, the JCL jobs owned by your username appear. HELLOCBL is the JCL job name previously submitted. Expand **HELLOCBL** output to view sections of the output as shown in Figure 26.
529
+
22. As a result, the JCL jobs owned by your username appear. HELLOCBL is the JCL job name previously submitted. Expand **HELLOCBL** output to view sections of the output as shown in Figure 23.
581
530
582
531

583
532
584
-
*Figure 26. HELLOCBL output*
533
+
*Figure 23. HELLOCBL output*
585
534
586
-
587
-
588
-
26. Select **COBRUN:SYSPRINT(101)** to view the COBOL compiler output. Scroll forward in the COBOL compile to locate the COBOL source code compiled into an executable module as shown in Figure 27. Observe the Indicator Area in column 7, A Area beginning in column 8, and B Area beginning in column 12. Also, observe the period (.) scope terminators in the COBOL source.
535
+
23. Select **COBRUN:SYSPRINT(101)** to view the COBOL compiler output. Scroll forward in the COBOL compile to locate the COBOL source code compiled into an executable module as shown in Figure 24. Observe the Indicator Area in column 7, A Area beginning in column 8, and B Area beginning in column 12. Also, observe the period (.) scope terminators in the COBOL source.
589
536
590
537

591
538
592
-
*Figure 27. COBOL compiler output*
593
-
594
-
539
+
*Figure 24. COBOL compiler output*
595
540
596
-
27. View the COBOL program execution by selecting **COBRUN:SYSOUT(104)** from the LEARNCOBOL in the Jobs section of Zowe Explorer as shown in Figure 28.
541
+
24. View the COBOL program execution by selecting **COBRUN:SYSOUT(104)** from the LEARNCOBOL in the Jobs section of Zowe Explorer as shown in Figure 25.
597
542
598
543

599
544
600
-
*Figure 28. COBOL program execution*
601
-
602
-
545
+
*Figure 25. COBOL program execution*
603
546
604
-
28. The following URL is another excellent document describing the above VSCode and Zowe Explore details with examples:
547
+
25. The following URL is another excellent document describing the above VSCode and Zowe Explore details with examples:
0 commit comments