Re: Novice Question About Console I/O

From: Rich Chilausky (rchilausky_at_nc.rr.com)
Date: 01/09/04


Date: Fri, 09 Jan 2004 00:05:26 GMT

I replaced my display ... with display ... at line x column y. It did change the
behavior. It opened a "screen" window, but all else was the same. The window was
  not the command prompt window.

This is the scenario that I am trying to prove in. I have a working Cobol
program that requires a modest amount of configuaration information at startup.
I want to be able to invoke the program via a command prompt window or over a
telnet connection, supply the information required via line oriented prompts,
and then let it compute right along. Perhaps I need a totally different approach?

Cheers,
Rich

Donald Tees wrote:
> Rich Chilausky wrote:
>
>> Donald,
>>
>> Thanks for your response. In the Fujitsu Cobol V3 PROGRAMMING-STAFF
>> ide, when I open the project and right click the source code of the
>> main program, nothing happens. A left click selects the file, a double
>> left click opens the editor window populated with the source code.
>> Suggestions on where I've gone astray?
>>
>> Is there another method to accomplish the same end?
>
>
> mmm .. I am not sure how you managed to get it to link, as it will not
> link correctly without you selecting either one or the other. When I
> right click on the source, I get a window with "folder" at the top. This
> is PSTAFF you are using?
>
> A display with line numbers will force the issue ... change the "display
> X" statements with "display x at line x column y" where x and y are
> integers (either WS or literal). That may do the trick for you. Or try
> opening the original window with a "display space at line 1 column 1"
> before starting.
>
> Donald
>
>>
>> Cheers,
>> Rich
>>
>> Donald Tees wrote:
>>
>>> Rich Chilausky wrote:
>>>
>>>> I am using Fujitsu Cobol V3 (the free version) to learn Cobol. I am
>>>> doing simple console I/O. I read from the keyboard and write to the
>>>> screen. The compile/link/execute sequence in the Fujitsu Cobol V3
>>>> works as advertised. I read from the keyboard and write to the
>>>> console window via ACCEPTs and DISPLAYs. The program behaves as
>>>> expected. I did a static link and generated an executable that runs
>>>> from my home directory. When I invoke the executable in a Windows
>>>> XP command prompt window, it runs just the way it did in the V3 ide.
>>>> It brings up a console window and prompts for my input. I had
>>>> expected it to use the command prompt window for the DISPLAY
>>>> destination. I want to read from the keyboard and write to the
>>>> command prompt window. I've searched the documentation that comes
>>>> with the compiler environment, but have been unable to figure out
>>>> how to write to the command prompt window. I suspect it is my Cobol
>>>> naiveté concerning i/o that prevents me from seeing the solution in
>>>> the documentation. Thanks in advance for your help.
>>>>
>>>> Cheers,
>>>> Rich Chilausky
>>>>
>>>
>>> Go back to the IDE, find the source code of the main program, and
>>> right click on it. Select "Main". Change the option from "display"
>>> to "window", then recompile and link. You will have to force a
>>> rebuild, as the change will not trigger it.
>>>
>>> It should work the same in both the IDE and the target machine. Note
>>> that once you go to a window rather than a console, you can use
>>> accept and display with line numbers and attributes, or you can use a
>>> screen section.
>>>
>>> Donald
>>>
>>
>



Relevant Pages

  • Re: SVGA, LCD, Win CE 6.0 and PB
    ... site addressing display drver issues, not to mention the source code. ... travel down thru Win CE from boot.ini to the place genrating final LCD ... I can have a desktop larger than physical screen window. ...
    (microsoft.public.windowsce.platbuilder)
  • Question about Full screen exclusive mode
    ... I use ScreenManager class that has been presented in David Brackeen's book. ... The graphics card enters the selected mode but the window content is painted only to the level of windows display mode.For example. ... After returning to the Windows, the settings dialog window is repainted with the content of the frame that is under settings dialog. ...
    (comp.lang.java.programmer)
  • Re: display array in a frame wnd
    ... I have to display results. ... The window can be used in all the program thanks to the name "source image". ... CFrameWnd* pw; ... Why is this not in an OnPaint handler? ...
    (microsoft.public.vc.mfc)
  • Re: display array in a frame wnd
    ... you have to create an app that is suitable for displaying an image. ... There would never be a need to create a frame window; it is not at all clear why such code ... I have to display results. ... Why is this not in an OnPaint handler? ...
    (microsoft.public.vc.mfc)
  • Re: Need a non-interactive service to open dialog on input desktop
    ... make remote COM calls to a remote COM object? ... account) on machine B. On NT, either of these services was able to ... interact with the user by opening the user's window station and desktop. ... When the service is started, it does not display the dialog ...
    (microsoft.public.win32.programmer.ole)