|
Is your purpose
<br />
m_tooltip.Create(this);<br />
TOOLINFO ti;<br />
ti.cbSize = sizeof(TOOLINFO);<br />
ti.lpszText = "ppp";<br />
ti.hinst = AfxGetInstanceHandle();<br />
ti.hwnd = m_Rich.m_hWnd;<br />
<br />
ti.uFlags = TTF_SUBCLASS | TTF_IDISHWND;<br />
ti.uId = (UINT) m_Rich.m_hWnd;<br />
m_tooltip.SendMessage(TTM_ADDTOOL, 0, (LPARAM) &ti);<br />
|
|
|
|
|
hi,
Thanks for ur reply,
Actually i am doing chatwindow project in vc++,I took two richeditcontrols one is for write the text and send the text messages and emotions also,Another richeditcontrol is to receive that textmessages and emotions,
I have the emotions dialog, in that emotions dialog tooltips are running on that emotions dialog only, i sent that emotions from first richeditcontrol to second richeditcontrol,then the second richeditcontrol received that emotions but it did not display any tooltip on that emotions ,my task is i should get that tooltips on second richeditcontrol(same as skype chatwindow in skype) also i tried so much but i didnt get,
thanks in advance.
-- modified at 7:45 Saturday 9th September, 2006
maheshkanth
|
|
|
|
|
You said that a richedit has tooltip and another richedit doesnt tooltip,right?
|
|
|
|
|
Hi,
Anyone knows how to detect mouseclicks in the child window by CHTMLEDITVIEW ( base class ) MFC VC++ .NET 2003 ?
When i open a powerpoint.ppt from the Main frame's menu, the powerpoint slides are open in the child window. However, i am unable to detect any mouse clicks using WM_LBUTTONUP on the CChildFrame.
Anyone can guide me? Need help urgently.
thanks.
terr
|
|
|
|
|
You need to handle OnParenNotify .
|
|
|
|
|
tks but do u mind to elaborate more? im rather new to C++ .Net using MFC. so i got problem on how to use the function u mention.
terr
|
|
|
|
|
Hi ,
thanks so much for telling me to use onParentNotify. I managed to detect the mouseclick .
thanks so much.
really appreciate.
but would like to check if it is possible to detect mouseclick when i make the powerpoint slide FULL SCREEN? it seems like i cannot detect it. Only within the Child frame.
Any solutions?
|
|
|
|
|
Hi
Please look at this my VS 2005 screenshot.
I am trying to learn resource in VC++.
http://img109.imageshack.us/img109/8540/resourcevh8.jpg
Resources are in VC++ differnet than C#.I see that it includes GUI tools.So i want to see that resources are loaded by
<br />
wcex.lpszMenuName = MAKEINTRESOURCE(IDR_MENU1);<br />
or<br />
wcex.hIconSm = LoadIcon(wcex.hInstance, MAKEINTRESOURCE(IDI_SMALL));<br />
So i think that if i include my new resorces files to my project i can select what i want.I added header files.
<br />
#include "resource.h"<br />
#include "resource1.h" <br />
#include "resource2.h"<br />
I hope i don't make mistake yet.
But VC++ gives same names to resources.For example(in screenshot)
i added as.rc and Name.rc
It gives same name to my resources. for example IDR_MENU1 are same same both as and name.
So how can i add resource to my solution that i can select whatever i want and hasn't got same name.What is wrong here?How can VC++ understand which one i include
for example i write
wcex.lpszMenuName = MAKEINTRESOURCE(IDR_MENU1);
Is IDR_MENU1 belongs to Name.rc or as.rc?SOmething wrong here but ı don't understand and confused about adding new resources and using it.
Compiler's error is :
CVTRES : fatal error CVT1100: duplicate resource. type:ICON, name:1, language:0x041F
LINK : fatal error LNK1123: failure during conversion to COFF: file invalid or corrupt
I am looking for your answers.
Thanks
|
|
|
|
|
You are asking for trouble if you want to add more than one resource file to your project. It's a bad idea to create a pool of resources, they will all be compiled into your exe bloating the size. Only include the resources you want to use.
If you are using the same resources in several projects, I advise you to create a resource only dll, and load that dll into each of your projects.
As for your name conflicts, you have assigned the same id to two icons. If you look in your #define files for the resources, find the #defines for the icons, and make sure they do not have the same number. Icons in particular are used outside your code, for example the icon show in 'explorer' is the icon with the lowest id, so it's not possible to have two icons with the same id.
|
|
|
|
|
Thanks for answer
But still i don't understand.
Yes It's a bad idea to create a pool of resources but i only want to test resources in vc++ ide.
So is assigning to same name to differnet resorces items normal?In my screenshot you can see ide assign items same name.But i think it must assign name by mixing with its resource file name.Right?
Also i said that:
wcex.lpszMenuName = MAKEINTRESOURCE(IDR_MENU1);
Now i select IDR_MENU1 also i can change this.So ı can use whaetever i want.We can bind resource to our class with these codes
Is this right?
If right. so ide must give differnet name for new added resouce items.
Can you please explain this for me.
|
|
|
|
|
I have win200box with vc6sp5, but i am not gettin compiled an application which uses Baloon Tools tips, the errors i am getting are like.
error C2039: 'szInfo' : is not a member of '_NOTIFYICONDATAA'
c:\program files\microsoft visual studio\vc98\include\shellapi.h(500) : see declaration of '_NOTIFYICONDATAA'
The dlls have been updated by service pack but not the header files, this is the main cause i think,
How to solve this issue?
Thanx In Advance
Z.A
|
|
|
|
|
|
error C2039: 'szInfo' : is not a member of '_NOTIFYICONDATAA'
c:\program files\microsoft visual studio\vc98\include\shellapi.h(500) : see declaration of '_NOTIFYICONDATAA'
error C2039: 'szInfoTitle' : is not a member of '_NOTIFYICONDATAA'
etc etc.
Z.A
|
|
|
|
|
I using in vs2003 without problem but see here[^] maybe it is some helpful to you
|
|
|
|
|
try adding #define _WIN32_IE 0x0500 to your stdafx.h header file, before you include any other headers. According to MSDN some members of the structure are only supported in version 5.0 and later of shell32.dll, but it doesn't say which members.
|
|
|
|
|
|
In that case you might want to open shellapi.h and check if there are any restrictions on using the structure.
|
|
|
|
|
Hi, im using vc++ 2005 express edition,
my application is win32 console application,i created new project in that with settings of "Empty Project" .
While i compiling my appli, it shows me the error as
d:\esim\lib\esimmain.cpp(84) : error C2664: 'MessageBoxW' : cannot convert parameter 2 from 'const char [31]' to 'LPCWSTR'
Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
the code which error shows:
MessageBox( hWnd, "Model DataBase Creation Failed in Debug Mode", "ERROR", MB_OK );
whatever i give in quoatations in the coding it shows me the same error.
Whats the reason?
Pls help me?
Anu
|
|
|
|
|
if you run this code whats hapenningMessageBox( hWnd, _T("Model DataBase Creation Failed in Debug Mode"), _T("ERROR"), MB_OK );
|
|
|
|
|
I coded like that but it shows the error as _T():Identifier is not found.
Anu
|
|
|
|
|
|
You are passing an ANSI string to a UNICODE function. Either switch to a MBCS build, or #include <tchar.h> and wrap your strings in the _T() macro as Whitesky suggested.
|
|
|
|
|
someone would tell me why when i add a combox control to a dialog recouse and enter some items in its data-property and press "Ctrl+T" to test the dialog but the combox showed nothing although u want to list its datas.
Thanks.
|
|
|
|
|
Hope I understood your question
when you press Ctrl+T it show dialog and values arent in combobox but i test and it work it show dialog and values in combo how to insert value to combox do you insert in property window ->Data
|
|
|
|
|
Yes,I did do it like you said. i insert values to combox in its property window ->Data. but the values couldn't appear when it was tested or run.
|
|
|
|