Hello!
I am struggling with some bizarre errors when using DISPLAY particularly if I try this:
DISPLAY "SHOW FIELD ON SCREEN? (Y/N) (X = EXIT): " WITH NO ADVANCING.
The OpenCOBOL Compiler produces weird errors:
./SchemaCreator.cobc:75: error: 'X' cannot be used here
./SchemaCreator.cobc:75: error: 'Y' cannot be used here
./SchemaCreator.cobc:75: error: syntax error, unexpected NO
./SchemaCreator.cobc:75: error: invalid symbol '!' - skipping word
invalid symbol ! - there isn't a "!" in the DISPLAY statement..?.
Before this there are lots of these type of DISPLAY commands:
DISPLAY " (X = EXIT): " WITH NO ADVANCING.
Which produces no errors! I thought (perhaps assumed?) that COBOL's DISPLAY command was similar to BASIC's PRINT and didn't have the "foibles" of C#/C++...
Any ideas why it doesn't like my DISPLAY statement?
Weird error using DISPLAY
- Anuj Dhawan
- Founder
- Posts: 2802
- Joined: Sun Apr 21, 2013 7:40 pm
- Location: Mumbai, India
- Contact:
Re: Weird error using DISPLAY
An educated guess - is the code in correct "area" for DISPLAY? May be show the actual code, a screen shot?
Thanks,
Anuj
Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
Anuj
Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
-
- Registered Member
- Posts: 15
- Joined: Wed Oct 22, 2014 8:51 am
Create an account or sign in to join the discussion
You need to be a member in order to post a reply
Create an account
Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute