I m referring to a tutorial book of database using ADO.
The problem is i have to get the result displayed in CListCtrlEx for which the tutorial book says i have to copy three files-CtrlExt.cpp, CtrlExt.h,
and CtrlExt.Inl-from the DAOVIEW example into the source code directory for my application.
I serached for these 3 files in the VC98\MFC\SRC\
But i could find the files there...so i even tried to download the files to the above folder and then added them to my project but still i get the
error : CListCtrl undeclared identifier
error : Cannot open the file CtrlExt.h
How do i use this CListCtrlEx class so that i can add columns and data to the client application ?
BackGround : Its a MDI with ListView as Base class .
Kindly tell me stey by step process to get rid of this error and use the CListCtrl class.
You've got several things going on here. Trying to do them all at once might not be your best bet. I would suggest first getting familar with a list control (in 'report' mode) and the related CListCtrl class. When you are able to add columns and items, then start looking at the CListCtrlEx class and the extra features that it offers (you may find it altogether unnecessary). That class can be found here.
There's also the issue with reading records from that database. That is an exercise in itself. You might want to start here.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
I m already through the CListCtrl class .With those classes i simply created a OnCreate Message Hnadler and created a ListView .There i had to add columns using InsertColumns()...Y here for CListCtrlEx do i have to add files to my project and still it is not working.As a matter of fact i do not even have the files mentioned above, in my DAOVIEW example.
I am using VS2008 on XP and I'm having trouble with the debugger fully terminating the process of my application after I am done debugging. Basically, the machine still thinks the exe is running so that I or the compiler cannot delete the file, leaving me unable to recompile. The problem seems to happen at completely random times and I am not able to reliably reproduce it. I have run ProcessExplorer and can see when the devenv starts the process and seems to release it. It does not appear to be running anywhere else.
The program is fairly small (few hundred lines) and deals with writing a few things to the registry and logging events with the NT event log.
I'm recently upgraded to VS2008 (new program though) and have never had this problem before. Any insights or troubleshooting tips would be appreciated.
P.S. Rebooting obviously fixes the problem, but I can't afford to do that 10 times a day.
However, I just figured out the problem. Apparently, after you open an event created be the application the event viewer opens the exe to access the message resources in the file. I didn't figure this out before because simply having the event log open doesn't cause the problem, you must open the actual event. The event viewer remains in control of the exe until the whole thing is closed, not just the event. I was sure I tried that before but I guess I didn't.
I'm trying to import in my MFC project some custom form user control made with c#. Now if I try to import them in a dialog following the msdn tutorial I have no problem. Instead If i try to import them in a cpanedialog I'm not able to initialize the control (if I look at the control value in debug mode it is always NULL). Now my question is:
It is possible to host the control or it is the same situation of the dialogbar in which as MSDN said can not be host form control?
PS To host the control I have included the clr support than I have made these three passage:
1) in header file I have add CWinFormsControl<mbrPropertyGrid::PropertyGrid> m_ctrl;
2)then to the cpp file of the panedialog I have added a DDX control where IDC_CTRL2 is a static tex used as placeholder DDX_ManagedControl(pDX, IDC_CTRL2, m_ctrl);
3) at least in a specific method I use the control
Yes I have the feature pack installed but the controls provided are too limited...the propertygridcontrol doesn't offer the opportunity to make a tree like control in witch the line with the expansion marquee could locate also another control.
So to overcame this problem I have thought that a solution will be to import a c# control...
my function f_my() receive identifier
of control, for example
How do set type of argument?
And how this function to call for execution?
As show - unproperly:
error C2660: 'GetDlgItem' : function does not take 1 arguments