Step Into C · Lesson 24 · Windows C
The Real Windows API
windows.h, GetLastError, file handles, virtual memory, GetProcAddress and your own PE headers.
- ~50 minreading and coding
- 5missions
- membersaccess
- Win32real Windows API
Part of Step Into C. The full lesson, its missions and the real compiler and debugger are in the course. Try a free lesson first to see how it works.
In the Windows-style lesson you implemented imitations of API functions. This lesson calls the real Win32 API: #include <windows.h>, and every function used here is one Windows itself exports from kernel32.dll.
In this lesson
- Now for real
- Reading the documentation
- Errors: GetLastError
- A vs W
- Handles: open, use, close
- Virtual memory
- Finding functions at run time
- Your own executable in memory
- Where to practice
Missions
- Hello, kernel32
- Files through handles
- Pages of memory
- Look it up yourself
- Read your own headers