Window.Title Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets a string used for the window title.
public:
property Platform::String ^ Title { Platform::String ^ get(); void set(Platform::String ^ value); };
winrt::hstring Title();
void Title(winrt::hstring value);
public string Title { get; set; }
var string = window.title;
window.title = string;
Public Property Title As String
Property Value
The string used for the window title.
Examples
public MainWindow()
{
InitializeComponent();
Title = "App title";
}
Note
The XAML version is only available for Windows App SDK 1.3.1 and upper.
<Window
...
Title="App title">
...
</Window>
Remarks
For more information, see Title bar customization
By default, the title bar shows the app's display name as the window title. The display name is set in the Package.appxmanifest
file. To replace the title with custom text, set the Window.Title
property to a text value, as shown in the Examples.
In addition to the title bar, this string is used in other system UI such as the application switcher (Alt-Tab).
This is a wrapper for SetWindowText.
If ExtendsContentIntoTitleBar is set to true
, this value is not displayed by the title bar.
Applies to
See also
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for