Skip to content

Commit 502b349

Browse files
authored
Tweak "Walkthrough: Create a traditional Windows desktop application (C++)" (#5576)
* Fix "does" typo in "Walkthrough: Create a traditional Windows desktop application (C++)" * Replace "length" with "height" in "Walkthrough: Create a traditional Windows desktop application (C++)" * Fix outdated mentions of `CreateWindow` in "Walkthrough: Create a traditional Windows desktop application (C++)"
1 parent 6fcd0f2 commit 502b349

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

docs/windows/walkthrough-creating-windows-desktop-applications-cpp.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ Next, learn how to create the code for a Windows desktop application in Visual S
216216
// szTitle: the text that appears in the title bar
217217
// WS_OVERLAPPEDWINDOW: the type of window to create
218218
// CW_USEDEFAULT, CW_USEDEFAULT: initial position (x, y)
219-
// 500, 100: initial size (width, length)
219+
// 500, 100: initial size (width, height)
220220
// NULL: the parent of this window
221221
// NULL: this application does not have a menu bar
222222
// hInstance: the first parameter from WinMain
@@ -250,7 +250,7 @@ Next, learn how to create the code for a Windows desktop application in Visual S
250250

251251
```cpp
252252
// The parameters to ShowWindow explained:
253-
// hWnd: the value returned from CreateWindow
253+
// hWnd: the value returned from CreateWindowEx
254254
// nCmdShow: the fourth parameter from WinMain
255255
ShowWindow(hWnd,
256256
nCmdShow);
@@ -316,9 +316,9 @@ Next, learn how to create the code for a Windows desktop application in Visual S
316316
// szTitle: the text that appears in the title bar
317317
// WS_OVERLAPPEDWINDOW: the type of window to create
318318
// CW_USEDEFAULT, CW_USEDEFAULT: initial position (x, y)
319-
// 500, 100: initial size (width, length)
319+
// 500, 100: initial size (width, height)
320320
// NULL: the parent of this window
321-
// NULL: this application dows not have a menu bar
321+
// NULL: this application does not have a menu bar
322322
// hInstance: the first parameter from WinMain
323323
// NULL: not used in this application
324324
HWND hWnd = CreateWindowEx(
@@ -337,15 +337,15 @@ Next, learn how to create the code for a Windows desktop application in Visual S
337337
if (!hWnd)
338338
{
339339
MessageBox(NULL,
340-
_T("Call to CreateWindow failed!"),
340+
_T("Call to CreateWindowEx failed!"),
341341
_T("Windows Desktop Guided Tour"),
342342
NULL);
343343

344344
return 1;
345345
}
346346

347347
// The parameters to ShowWindow explained:
348-
// hWnd: the value returned from CreateWindow
348+
// hWnd: the value returned from CreateWindowEx
349349
// nCmdShow: the fourth parameter from WinMain
350350
ShowWindow(hWnd, nCmdShow);
351351
UpdateWindow(hWnd);
@@ -503,7 +503,7 @@ As promised, the complete code for the working application follows.
503503
// szTitle: the text that appears in the title bar
504504
// WS_OVERLAPPEDWINDOW: the type of window to create
505505
// CW_USEDEFAULT, CW_USEDEFAULT: initial position (x, y)
506-
// 500, 100: initial size (width, length)
506+
// 500, 100: initial size (width, height)
507507
// NULL: the parent of this window
508508
// NULL: this application does not have a menu bar
509509
// hInstance: the first parameter from WinMain
@@ -524,15 +524,15 @@ As promised, the complete code for the working application follows.
524524
if (!hWnd)
525525
{
526526
MessageBox(NULL,
527-
_T("Call to CreateWindow failed!"),
527+
_T("Call to CreateWindowEx failed!"),
528528
_T("Windows Desktop Guided Tour"),
529529
NULL);
530530
531531
return 1;
532532
}
533533
534534
// The parameters to ShowWindow explained:
535-
// hWnd: the value returned from CreateWindow
535+
// hWnd: the value returned from CreateWindowEx
536536
// nCmdShow: the fourth parameter from WinMain
537537
ShowWindow(hWnd,
538538
nCmdShow);

0 commit comments

Comments
 (0)