我现在鼠标移动到CEdit控件上,ToolTip可以出现,但是我想实现在输入的时候出现ToolTip,应该怎么办?请高手指点!!!谢谢!!!
解决方案 »
- Installshield 12 安装包制作出错
- 单文档视图是否可以静态添加控件?
- 高分请教:如何在分层窗口正确合成前景和背景图片?具体情况见内
- 在多文档MDI下如何实现列表的自动刷新
- 娱乐一下:赵公忠祥列传
- 请问如何在对话框中翻转控件?
- 请问VC这论坛内那个版面人气最好
- 高手帮忙看看这段代码的问题?
- LINK : warning LNK4098: defaultlib "LIBCMT" conflicts with use of other libs; use /NODEFAULTLIB:library
- 如何将浏览器发过来的诸如“%E5%B2%E7%D4%E5%62”请求转为中文?
- 请问各位高手:在多文档模式的应用程序中,如何给主框架加图片做背景?怎么加?
- 有关编译的问题
因为只有鼠标相关的消息才能引发Tooltip
{
public:
virtual BOOL PreTranslateMessage(MSG* pMsg);
CAboutDlg();// Dialog Data
//{{AFX_DATA(CAboutDlg)
enum { IDD = IDD_ABOUTBOX };
//}}AFX_DATA // ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CAboutDlg)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL// Implementation
protected:
CToolTipCtrl m_tooltip;
virtual BOOL OnInitDialog();
//{{AFX_MSG(CAboutDlg)
// No message handlers
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};BOOL CAboutDlg::OnInitDialog()
{
CDialog::OnInitDialog(); // CG: This was added by the ToolTips component.
// CG: The following block was added by the ToolTips component.
{
// Create the ToolTip control.
m_tooltip.Create(this);
m_tooltip.Activate(TRUE); // TODO: Use one of the following forms to add controls:
// m_tooltip.AddTool(GetDlgItem(IDC_<name>), <string-table-id>);
m_tooltip.AddTool(GetDlgItem(IDC_EDIT1), "<text>");
}
return TRUE; // CG: This was added by the ToolTips component.
}