in the Test_Doc.cpp file(SDI_Appliction), i use the following code:
CTestFontDialog sfdlg; // CTestFontDialog is derived from CFontDialog
and this code is in the OnInputFontDialog()
CFont *pFont = GetFont(); // Fehler
the OnInputFontDialog() is in TestFontDialog.cpp this class is derived from CFontDialog.
How can i see what fail the assertion?
m_hWnd = 0x00000000
maybe this is why?
i need to pass the window through this ctor, the create function did not work because i do not have
a dialog in my rc, all what i need to do is to modify the normal font dialog(disable some fields in it).
CTestFontDialog(LPLOGFONT lplfInitial, DWORD dwFlags, CDC* pdcPrinter, CWnd* pParentWnd) :
CFontDialog(lplfInitial, dwFlags, pdcPrinter, pParentWnd)//pParentWnd ???(is this the window of the sdi appliction???)
I am writing a application in which i use the stl list. through this list i m able to inserting the items but not able to remove the item from specific position. this is my class
ClipEntry(const ClipEntry& r);
const ClipEntry& operator=(const ClipEntry& r);
bool operator == (const ClipEntry& r);
I am inserting the items like this
HRESULT ClipPlayer::AddClip(char* path, ClipEntry** ppClip)
it = m_Clips.insert(m_Clips.end(), ClipEntry());
ClipEntry *pClip = &(*it);
*ppClip = pClip;
Is your m_Clips really declared as above? I.e., does it store pointers to ClipEntrys?
If it does, you shouldn't need to write a comparison operator for ClipEntry since std::list::remove() would simply compare the pointers in order to find a match. (Referring to you ongoing discussion with Stuart.)
"It's supposed to be hard, otherwise anybody could do it!" - selfquote "High speed never compensates for wrong direction!" - unknown
Last Visit: 31-Dec-99 19:00 Last Update: 8-Feb-23 13:58