|
I tried this and it does not help.
I noticed that I dont get any wm_notify messages.
I guess they are "kidnapped" somewhere along the way.. but where?
avivhal
|
|
|
|
|
Aviv Halperin wrote:
I tried this and it does not help.
Meaning that EnableToolTips() has been called and both entries are in the dialog's message map? How are you verifying that OnToolTipNotify() is not getting called?
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Yes, EnableToolTips() has been called and both entries are in the dialog's message map.
I tried putting a break point in the message handler in debug mode and never got to the break point.
Then I tried with the spy++ to find out if any notify message is sent and non are sent.
I have complex structure here that might be the reason:
I have a dialog box with a tab control. The tab control has a few pages which are all implemented as child dialogs of the tab control.
I'm trying to add tool tips to some of the controls of the tab pages dialogs.
Thanks.
avivhal
|
|
|
|
|
Did you call EnableToolTips from within your dialog window?
We are men. We are different. We have only one word for soap. We do not own candles. We have never seen anything of any value in a craft shop. We do not own magazines full of photographs of celebrities with their clothes on. - Steve
|
|
|
|
|
hi all
i have a modeless dialog which i call, kind of a waiting dialog if you like
i use
CCPServerWait* m_pWaitDlg;
m_pWaitDlg = new CCPServerWait;
m_pWaitDlg->Create(IDD_DCPSERVER_WAIT
m_pWaitDlg->m_wait_mes = "ConfimingDetails...Please Wait";
m_pWaitDlg->UpdateData(FALSE);
m_pWaitDlg->CenterWindow(CWnd::GetDesktopWindow());
m_pWaitDlg->ShowWindow(SW_SHOW);
m_pWaitDlg->UpdateWindow();
however im getting a debug assertion error on wincore.cpp when i run my program
when i look at the value CCPServerWait has when i step through hWnd is equalling nothing
CCPServerWait {CCPServerWait hWnd=???} CCPServerWait
this used to work fine until i added in the line of code below before the
dialog is called
ok = SQLCreateDataSource(m_hWnd,"CP_CMIS_CON");
which allows the user to create a Datasource
if i take this out the above works, but with it in
it throws me out an error on the m_pWaitDlg->UpdateData(FALSE); line
i assume this is because hWnd=???
but i dont know how to fix it
any ideas ????
|
|
|
|
|
You're calling UpdateData() but the controls do not exist yet. Remove that call altogether. Then in the dialog's OnInitDialog() method, use SetWindowText() instead. The CenterWindow() call should be moved to the dialog's OnInitDialog() method.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
thanks
when i call the dialog though, i pass some kind of text to it but thats different
each time i call the dialog
i was using
m_pWaitDlg->m_wait_mes = "Confiming School Details...Please Wait";
how do i do it now ?
thanks
si
|
|
|
|
|
si_69 wrote:
i was using
m_pWaitDlg->m_wait_mes = "Confiming School Details...Please Wait";
how do i do it now ?
No change. m_wait_mes should be a CString object. The dialog should also have a CEdit object, whose SetWindowText() method will get called with m_wait_mes as the parameter.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Hello everybody,
I am a beginner in com programming, and i have a question:
I have created an ATL 3.0 project including a simple object named MyObj with the attribute of 'appobject' on it's coclass. It has a property named MyString that holds string values. I have successfully built it and then tested it from vb. I have access to MyString property directly without instantiating MyObj. everythings is Ok.
but I have problem with VC. From a Console application which has access to that type library (via import directive) MyString property cannot be accessed without qualification. With the statement:
MyString = "Hello world!";
compiler generates following error:
error C2065: 'MyString' : undeclared identifier
what is the problem? do you think i should use a special syntax?
if so, would you please help me to know how i can use it?
thanks in advance
Roozbeh
|
|
|
|
|
I call the function 'Navigate2' of IWebBrowser2 interface as following:
_variant_t varURL(_bstr_t("www.codeproject.com"));
_variant_t varMyHeaders(_bstr_t("Cookie: JSESSIONID=0000Fkdkdaourejlasdfa"));
_variant_t varFlags((short)navOpenInNewWindow);
_variant_t varTargetFrameName(_bstr_t("_BLANK"));
_variant_t varEmpty;
m_pWebBrowser->Navigate2(
&varURL,
&varFlags,
&varTargetFrameName,
&varEmpty,
&varMyHeaders);
But the content of varMyHeaders is not added to the default Microsoft Internet Explorer headers. I don't know what the problem is.
Is there anybody who met similar problems? Any suggestion will be appreciated. Thanks very much.
|
|
|
|
|
I think the problem is that the headers are a byte array rather then a unicode string.
This is from MSDN.
The post data specified by PostData is passed as a SAFEARRAY Data Type structure. The variant should be of type VT_ARRAY and point to a SAFEARRAY Data Type. The SAFEARRAY Data Type should be of element type VT_UI1, dimension one, and have an element count equal to the number of bytes of post data.
If you don't kill me you will only make me stronger
That and a cup of coffee will get you 2 cups of coffee
|
|
|
|
|
Hi,
In your example you use www.codeproject.com, in your real application do you use "http://www.yoururl.com" ?
Only here is an exert from MSDN (I've bolded the relevant part):
------------------
Headers
[in] Pointer to a value that contains the HTTP headers to send to the server. These headers are added to the default Microsoft Internet Explorer headers. The headers can specify things such as the action required of the server, the type of data being passed to the server, or a status code. This parameter is ignored if a URL is not an HTTP URL.
I've used the following in a previous app. and it added the headers fine:
strURL = "http://server1/CustomApp/validate.asp";
COleVariant vtEmpty;
long lFlags = 4;
m_ctlWeb1.Navigate2(COleVariant(strURL),
COleVariant(lFlags, VT_I4),
COleVariant("_self"),
&vtEmpty,
COleVariant("CUSTOM:1\r\fXYZXYZ:1234\r\f"));
Hope this helps,
Andy
|
|
|
|
|
Hi!
I have an object which I need to check regularly. I want the following:
1. a member storing when the object was last checked
2. a member storing the length of time between checks
This is for when I run my program if I check the current time vs the last checked time and then determine if the length of time between checks has been exceeded I can then perform an update.
My question is what should I use to store these members? Should I use a SYSTEMTIME structure or is there a better method? Can I compare SYSTEMTIME with the current time and do operations like subtract to find if the length of time between checks is exceeded?
Are there any problems with using SYSTEMTIME?
|
|
|
|
|
Something like:
class CMyObject
{
public:
void Check( void )
{
m_timeLastChecked = COleDateTime::GetCurrentTime();
}
void GetCheckAge( COleDateTimeSpan &timeAge )
{
timeAge = COleDateTime::GetCurrentTime() - m_timeLastChecked;
}
private:
COleDateTime m_timeLastChecked;
};
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Thanks
I have never used that class before. Is there any particular reason why to use it instead of SYSTEMTIME or CTime? Looking at it I may also use COleDateTimeSpan to store the time between checks.
|
|
|
|
|
Anonymous wrote:
Is there any particular reason why to use it instead of SYSTEMTIME or CTime?
A CTime object is only good from January 1970 through January 2038. A COleDateTime object covers that range and a lot more.
Anonymous wrote:
Looking at it I may also use COleDateTimeSpan to store the time between checks.
What's to store? If you are wanting to know the elapsed time since the last check, you'd be comparing the last-checked time against the current time.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
DavidCrow wrote:
What's to store? If you are wanting to know the elapsed time since the last check, you'd be comparing the last-checked time against the current time.
I also need to store a timespan I think. This is so I can store an amount of time like 30 days. I can then decide if an update must be done by looking at the last time an update happened then adding the timespan which is the length of time between updates and then comparing with the current time.
It will be like looking for web updates every 5 10 or 30 days depending on a user setting.
|
|
|
|
|
Hi !
I'm trying to develop an hyperterminal-like application in VC++.
I use a CEdit control for logging data coming from a serial com port.
The problem is that I didn't find a good way to add text in the CEdit control.
This works too slow, and gives flickering effects.
Any advise will be welcome !
Thanks in advance.
Jeje.
|
|
|
|
|
Jeje wrote:
The problem is that I didn't find a good way to add text in the CEdit control.
What way(s) did you find that was not good?
Have you looked at ReplaceSel() ?
Yoiu could also add the incoming data to a CString object and then call SetWindowText() once.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
Hello,
I de-installed visual studio.NET. Recently I found out that the de-installer didn't remove the JIT debugger regestry settings from my system.
Now, when a program crashes, the debug dialog appeart and asks me if I want to debug the application. When I hit the retry button (to debug), I get this really annoying message box that says that the JIT debugger canno't be found. It also asks if I want to use the old debugger msdev.exe
After sweeping the geristry manually and removing every VS.NET and JIT entry I could find, the dialog still appears.
Does anyone know how I can solve the problem?
Thanks
A student knows little about a lot.
A professor knows a lot about little.
I know everything about nothing.
|
|
|
|
|
I solved the problem!
I just don't know why I didn't think of enabling the Just In Time debugger from VS 6.0
On the other hand, my registry is clean(er) than it was before
A student knows little about a lot.
A professor knows a lot about little.
I know everything about nothing.
|
|
|
|
|
Did you check this one?
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Aedebug
In "Debugger" String i have:
"C:\Program Files\Microsoft Visual Studio\Common\MSDev98\Bin\msdev.exe" -p %ld -e %ld
Papa
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
I have the same key, but there was another key: "PreVisualStudio7Debugger". Now I have removed the key..
You never know how much garbage an uninstaller leaves around...
A student knows little about a lot.
A professor knows a lot about little.
I know everything about nothing.
|
|
|
|
|
it is interested at windows system registery. You must clean this from windows system registery.
|
|
|
|
|
Hi,
Is there a method to replace a message to the top of the application message que.
Thanks and best regards.
Erkan Ermis
|
|
|
|