The MASM Forum

Miscellaneous => Irvine Book Questions. => Topic started by: NightLock on December 05, 2021, 03:44:08 AM

Title: Need to use ReadConsoleOutputCharacter, but it isn't prototyped in Smallwin.inc?
Post by: NightLock on December 05, 2021, 03:44:08 AM
Hi,

I'm trying to save the contents currently written in the console window to a buffer. As far as I understand (and please correct me if I'm wrong), I need the ReadConsoleOutputCharacter Win32 API function for this. However, when invoking it, I get told that the symbol is undefined. In the same program, invoking another function like WriteConsole works. To investigate, I checked the Smallwin.inc file that comes with the rest of the Irvine files, and for some reason the function isn't prototyped in there. It's strange because  the function is listed in Table 11-2 of the book, the book explicitly says that all Win32 functions are supported by the Irvine library, and Smallwin.inc even prototyped the Write version of this very function! Could someone help me figure out how I can use this function, maybe by adding the appropriate prototype to Smallwin.inc?

Thanks in advance!
Title: Re: Need to use ReadConsoleOutputCharacter, but it isn't prototyped in Smallwin.inc?
Post by: jj2007 on December 05, 2021, 04:03:00 AM
You can prototype it just before the invoke, embedded in the source.