|
|
I got it, thank you
I'm amumu, and you?
|
|
|
|
|
Hello all,
I need some help with CHtmlView.
What I need to achieve :- I am creatying an HTML file in memory and need to preview it to the user.
Current plan :- Create a temporary HTML file and open it in Internet Explorer
Alternate plan :- Create a frame window, with a CHtmlView and jump up this frame window. Now I need to transfer my in-memory HTML code into this CHtmlView. How do I do that please?
Warm regards
Buster
If I am awake and my eyes are closed, it does not necessarily mean that I am thinking of naked women.
|
|
|
|
|
So?
Nish
If I am awake and my eyes are closed, it does not necessarily mean that I am thinking of naked women.
|
|
|
|
|
I found that the easiest way was to create the temp html file and then navigate to that. There didn't seem to be an easier way to do it. I came across a few ideas in the ATL mailing list archives but nothing that seemed easy to implement.
Michael
|
|
|
|
|
If nothing else works I'll have to try that out
Nish
If I am awake and my eyes are closed, it does not necessarily mean that I am thinking of naked women.
|
|
|
|
|
If you want to load a HTML string from memory:
HRESULT hr;
IDispatch *pIDispatch = GetHtmlDocument();
IHTMLDocument2 *pIDoc;
IHTMLElement *pIBody;
hr = pIDispatch->QueryInterface(IID_IHTMLDocument2, (void**)&pIDoc);
hr = pIDoc->get_body(&pIBody);
hr = pIBody->put_innerHTML(_bstr_t("<b>Hello world</b>"));
(Error handling and clean up left as an exercise )
|
|
|
|
|
Thanks a lot
Nish
If I am awake and my eyes are closed, it does not necessarily mean that I am thinking of naked women.
|
|
|
|
|
hi
I used the datetimepicker control and I added a member variable for this control, but when i use UpdateData(); the problem occured with any date befor 1969-12-31. is it a bug in vc6? can I use this control for date before 1969-12-31 and how?
Best Regards
|
|
|
|
|
I use this control without any problems.
Even the year 1817 is reachable.
Your accompanying code must be teh problem.
Geert.
|
|
|
|
|
thanx
allways i got the following message:
(Debug Assertion failed!
program : file.exe
timecor.cpp
line:40)
this file (timecore.cpp)is done with vc6
Best Regards
|
|
|
|
|
So, what's on line 40 of timecor.cpp?
|
|
|
|
|
ASSERT(m_time != -1); // indicates an illegal input time
Best Regards
|
|
|
|
|
Hi,
Your problem is that the MFC CTime class actually uses the mktime() call internally. If you look at the definition of mktime() you'll see that it uses a time_t, which is a floating point value representing the number of seconds since, you guessed it, Jan 1 1970. The problem here is the fact that you're mapping your control to a CTime value. Open the ClassWizard and delete the mapped variable. Add it again, but make sure you select COleDateTime from the Variable Type combo. This should give you a much larger range of values.
Hope this helps.
------------------------
Derek Waters
derek@lj-oz.com
|
|
|
|
|
thanx
it is working now, does it work with date field of a access db?
Best Regards
|
|
|
|
|
Well, assuming that you're using some COM-based technology to access your Access DB (and I would imagine it'd be pretty tough otherwise!) then COleDateTime can easily be converted to a VARIANT of VT_DATE type using COleVariant. This will be exactly the format that Access's automation interface will be expecting.
------------------------
Derek Waters
derek@lj-oz.com
|
|
|
|
|
Hi CP adepts,
By using WriteProfileXXX() you can easily save some settings of your app
to the registry OR an INI file.
But if I choose for an INI file it is always created in the %windows% directory.
I'd like to keep it in the same directory as my app.
How can I become such a behaviour?
(without having to move it around myself of course)
Thanks.
|
|
|
|
|
You can use WritePrivateProfileXXX() which allows you to specify the path to the INI file.
|
|
|
|
|
Knew it must be possible.
Thanks.
P.S.: MS doesn't seem to promote the use of it.
"This function is provided only for compatibility with 16-bit versions of Windows."
|
|
|
|
|
Hi !
I want to build a c++ program that can interact with some sort of database! I'm not sure which database engine should i use. It's only a small program. Could anyone give me a hint of how to do it or refer some readings to me??
Thanks in advance
Cheers
|
|
|
|
|
Access is okay for small database applications that doesn't require a lot of users to access it at the same time.
MSDE is also very good for small standalone systems.
ADO is (in my view) the best way to access both of these databases via C++
Michael
|
|
|
|
|
Hi Micheal
Thank you for your response. I just wonder if you know any good tutorial that demonstrate accessing database by C++.
Cheers
|
|
|
|
|
a Multi select tree control that must be fast!
more easy more good!
thanks!
ZHANGYIFEI
|
|
|
|
|
Have a look on this site, I'm sure there's a class that already implements a fast multi select tree ctrl.
Normski. - Professional Windows Programmer
|
|
|
|
|
i have a problem when i'm capturing the whole Client area of a CVIEW... When I'm capturing the client area of CView in a bitmap, the borders and scrollbars are captured too....??
|
|
|
|