|
I apologise in advance, but:
The stl documentation in the MSDN *sucks*, big time. Half the time, I can't find what I want to know, and the other half is confusing as hell.
I can't help wondering that I could have been a pretty good stl programmer by now if it wasn't for the crap stl documentation that I have to read tolerate everyday.
I have the Jan 2001 MSDN library and I can't stand using this as a stl reference anymore.
I've come to rely on and love the MFC documentation over the last few years; its a shame the stl section is not as friendly.
Are there any good reference material out there for the stl, from beginners to advanced level? Online, Paperback, or the latest MSDN library maybe (not using .NET yet though!)
Any suggestions welcomed.
Rich. (p*ssed off big time! )
I Dream of Absolute Zero
|
|
|
|
|
As a reference I use this[^]one.
But it is certainly not a beginners tutorial.
Who is 'General Failure'? And why is he reading my harddisk?!?
|
|
|
|
|
Thanks for that.
I'm sure i'll come in handy in times of crisis.
I Dream of Absolute Zero
|
|
|
|
|
I really like "STL Programming from the Ground UP" by Herbert Schildt.. I find myself looking up stuff daily...
Rob
Whoever said nothing's impossible never tried slamming a revolving door!
|
|
|
|
|
Is this book more like a turorial for absolute beginners?
I would probably need something more along the lines of a reference with excessive explanations.
Who is 'General Failure'? And why is he reading my harddisk?!?
|
|
|
|
|
IMHO I would say it's probably geared more to beginners. It assumes no prior knowledge of STL but I still found that it covered everything I have ever needed.
You would probably want to stop by a bookstore and look through the book before you bought it. You might find it too simple, then again it may cover the stuff your looking for.
Rob
Whoever said nothing's impossible never tried slamming a revolving door!
|
|
|
|
|
|
Cool. I was thinking of getting myself another stl book.
This one looks right up my street.
I Dream of Absolute Zero
|
|
|
|
|
Theres a file I want to rewrite on the fly. If I write into it data less than the original number of lines, using writeString CFileStdio, then the remaining text from the original is stil there following my new lines. I dont want to kill the whole file and recreate it...I want it to always exist, but how do I go and empty out the file so the new data has a fresh clean slate?
Thanks,
ns
|
|
|
|
|
Open the file with the CFile::modeCreate flag set. This will create the file if it does not exist, or clear the existing contents if it does.
You can then use CFile::modeNoTruncate with the above, if you want to preserve the contents.
I Dream of Absolute Zero
|
|
|
|
|
I am trying for several days to stream RTF text which contains OLE objects (bitmaps) into a CRichEditCtrl. StreamOut works absolutly perfect. If I save the streamed out string to a file, I see the objects if I open the file with wordpad. But if I try to stream the string back into an other control, I only get the plain RTF formatted text and the OLE objects are missing!
So, is it not possible to stream in OLE objects into a RTF control?
What need to be done if I want to stream RTF text incl. OLE objects into a CRichEditCtrl?
Thanks in advance.
|
|
|
|
|
Well, it seems the other control isn't handling the ole objects (like, duh!). Look into GetIRichEditOle and SetOLECallback. I haven't tried implementing them myself, but they look to be the key things to get this to work.
Joel Lucsy
|
|
|
|
|
Thanks for you answer.
I also found that OLE stuff, but I am not sure what I should do with it. The M$ "documentation" of the OLE interface of CRichEditCtrl is practically nothing.
I also think, that somewhere in the CRichEditVIEW and CRichEditDOC classes something similar must be done in order to load RTF text with OLE objects. But unfortunately I can't use CRichEditView.
I hope someone can give me a hint about it.
|
|
|
|
|
I think this comment in Codeguru can be the solution of the problem:
http://www.codeguru.com/mfc/comments/27104.shtml
We must implement the IRichEditOleCallback interface. The most important method seems to be GetNewStorage!
You can find the full code if you follow the link above!
|
|
|
|
|
Hi all,
I need to bringup a scale control in inches upon my Edit Control, (as in the top of the Word Document )
Any Components are avilable??
Thanks in advance
Warm Regards,
KKR
|
|
|
|
|
after editing code:
void CDlgDelete::OnOK()
{ CString deleteID;
deleteID.Format("ID = %s", m_str_deleteID);
recordset.Find(AFX_DAO_FIRST, deleteID);
recordset.Delete();
recordset.Update();
recordset.Close();
database.Close();
CDialog::OnOK();
}
i run program and encountered messagebox error: syntax error(missing operator) in expression. how to correct it?
|
|
|
|
|
Have you used the debugger (or popped up a message box) to check and see what exactly the value of deleteID is after formatting it? There might be a quote missing somewhere.
|
|
|
|
|
okie i did what u suggested as follows:
deleteID.Format("ID = %s", m_str_deleteID);
AfxMessageBox(deleteID);
then i run and my message box read "ID=" instead of "ID=xxx"....so wat is wrong with my code?
|
|
|
|
|
Hi,
My current task is to find a way to add superscripted text to the title bar of a CDialog based window, as in "MyWindowsuperscript". My first thought was that there must be some control characters to embed in a CString that when sent to CWnd::SetWindowText(superscriptedText)would cause the text to be rendered. No luck on this front. Undaunted, I thought about making the superscripted text a graphic and drawing it in the Title Bar. I haven't been able to find any guidance on this approach for a CDialog derived class. Any help greatly appreciated!
I'm working in Visual C++ Version 6.
Thanks,
Doug
Doug Knudson
|
|
|
|
|
|
Hello
I was just wondering if anyone knows of a tool that aids converting a Visual Studio C++ app from MBCS to Unicode. I have this huge task ahead of me and any helpful utilities would be very useful. What I bascially want is something that scans through all my files and converts all instances of char to TCHAR, string functions such as strcpy to their TCHAR eqivalent and converts literal string such as "Hello" to _T("Hello") plus hopefully deals with some of the more subtle conversion issues.
Does anyone know of such a tool?
Thanks
Mark
|
|
|
|
|
This would definitely be a tool worth writing!
/ravi
Let's put "civil" back in "civilization"
Home | Articles | Freeware | Music
ravib@ravib.com
|
|
|
|
|
Hi
I use Visual Studio 6 and have made a dialog based MFC application that uses the registered Activex component called "MS communications control version 6" (MSCOMM32.OCX) . My program does serial communication via an RS232 interface. I tested it under XP and WinNT 4: It works when I add MSCOMM32.OCX to the system32 folder. It did not work under Win98 2nd Edition. The dialog box didn't even show up. When I installed Visual studio, it showed up and worked but when I closed the application, windows couldn't be shut down (fatal error). I want it to work without installing visual studio. Does anybody have an idea how I can make it work?
Thanks
|
|
|
|
|
Hi. I have a boolean member variable assigned to a check box, but when I pass theis variable to a function I get the follwoing warning:
Warning C4800: 'int' : forcing value to bool 'true' or 'false' (performance warning)
Declaring a local boolean and passing that works fine, just not the member variable from the check box. So, is a member variable of type 'BOOL', as assigned by Class Wizard, a true boolean?
CODE:
func(bool a); //definition
func(m_boolPar1); //call to func - doesn't work
bool b;
func(b); //works fine
Thanks in advance. Frustrated & bemused!!
|
|
|
|
|
You probably are passing your
func (bool a) ;
a BOOL - a MS typedef for int .
Change this
BOOL b = TRUE;
func (b); to
BOOL b = TRUE;
func (b!=FALSE);
This way, you use the !=-operator to produce a bool from your BOOL . You test for != FALSE instead of == TRUE , because TRUE used to be defined as 1, but you want any non-null to be treated as TRUE .
When MS designed MFC, there was no real C++ standard, and certainly no Microsoft-compiler capable of understanding it.
A few ugly things from this times are still around: BOOL instead of bool , CArray instead of std::vector , lacking const ness from many functions.
Who is 'General Failure'? And why is he reading my harddisk?!?
|
|
|
|