本文整理汇总了C++中TDocument::GetTitle方法的典型用法代码示例。如果您正苦于以下问题:C++ TDocument::GetTitle方法的具体用法?C++ TDocument::GetTitle怎么用?C++ TDocument::GetTitle使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TDocument
的用法示例。
在下文中一共展示了TDocument::GetTitle方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: GetApplication
//
/// Displays a message box with the error message passed as a string resource ID in
/// sid. By default, the message box contains either an OK push button or a question
/// mark icon. If an error message can't be found, PostDocError displays a "Message
/// not found" message. choice can be one or more of the MB_Xxxx message style
/// constants. This function can be overridden.
///
/// Returns an integer
/// identifying the MessageBox option (push-button) selected by the user.
//
uint
TDocManager::PostDocError(TDocument& doc, uint sid, uint choice)
{
PRECONDITION(GetApplication());
PRECONDITION(GetApplication()->GetMainWindow());
tchar buf[256];
if (GetApplication()->LoadString(sid, buf, sizeof(buf) / sizeof(tchar)) == 0)
#if BI_MSG_LANGUAGE == 0x0411
_stprintf(buf, "エラー: 文字列 ID %u が見つかりません", sid);
#else
_stprintf(buf, _T("Error: Message [string ID %u] not found"), sid);
#endif
if (choice != MB_OK)
choice |= MB_ICONQUESTION;
return GetApplication()->GetMainWindow()->MessageBox(buf, doc.GetTitle(), choice);
}