How do I change the title after my window has been created?
How do I change the title after my window has been created?
For instance here is a function example that performs the task I believe you are looking for.Code:SetWindowText(hwnd, szTitle);
happy coding!!!!Code:void setWindowCaption(HWND hwnd, TCHAR* szTitle) { TCHAR * szCaption[MAX_PATH + 64] wsprintf(szCaption, TEXT("%s - %s"), TEXT("TextEditor"), szTitle[0] ? szTitle : TEXT("Untitled")); SetWindowText(hwnd, szCaption); }
Last edited by andyhunter; 01-02-2005 at 05:45 PM.
i don't think most standard compilers support programmers with more than 4 red boxes - Misplaced
It is my sacred duity to stand in the path of the flood of ignorance and blatant stupidity... - quzah
Such pointless tricks ceased to be interesting or useful when we came down from the trees and started using higher level languages. - Salem