Disabling context menu in a console app

I simply want to disable the context menu whilst my console app is running.

I've looked at the link below for a bit and I think it is what I want but sadly cannot understand the syntax even though it is shown in plain text

https://msdn.microsoft.com/en-us/library/windows/desktop/ms686033(v=VS.85).aspx

Can anyone explain in layman's terms what the result of the syntax should be?

PS. I believe I need to use 0x0040.

Thanks!
you get a handle (windows for "pointer") to the console instance (its process ID, sort of). Then you send a message to it, telling it to change its settings. If you have permission to do that, it will, for that active session only, until you change it back.

the link you listed probably is insufficient.
You probably need to define a variable and call one of the "get process handle" routines (there are many, and I am out of that game, I don't know what the actual one you need is called). Then youll have to pass that value to the linked function to get it to work.





Thanks for the reply, maybe it won't as easy as I thought. I'll just have to wait till Monday to ask my teacher :(
Topic archived. No new replies allowed.