- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Is there a way to get the character that is already at a certain location in a console window?
For example: After opening a console window, one does:
CALL CLEARSCREEN($GCLEARSCREEN)
CALL SETTEXTPOSITION (INT2(1), INT2(5), rc)
CALL OUTTEXT ('Hello, everyone')
But then let's say you later the text in row 1 may have chaged as part of the program, so you want to know what character is at row 1, column 6. How do you find this out? I was hoping for something like GETTEXT(1,6,string) or something.
Is this possible?
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The example you quote is QuickWin. The text output is not to a console window it is to a program window and is output is as graphics. I do not think there is a screen buffer for the output text, What do yopu want the program to do? It is possible to have a 'console application' with a proper console. It is also possible to create and attach to an existing console from windows or quickwin applications. It might be worth reading the following link before going any further....
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear APP4619:
Thanks for the link - I had a few old Fortran programs that used to write to the screen using the old DOS commands with the escape characters - not worth translating to Quickwin.
This will give me a day of fun
Thanks
JMN
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If the text is printed to a formal console window you can read the text
BOOL WINAPI ReadConsoleOutput( _In_ HANDLE hConsoleOutput, _Out_ PCHAR_INFO lpBuffer, _In_ COORD dwBufferSize, _In_ COORD dwBufferCoord, _Inout_ PSMALL_RECT lpReadRegion );
http://msdn.microsoft.com/en-us/library/windows/desktop/ms684965(v=vs.85).aspx
Jim Dempsey

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page