Hi All I've come across a piece of code. This is defined in AtlBase.h line number 3977 BSTR Detach() { BSTR s = m_str; m_str = NULL; return s; } Now in this...
... Yes, this is correct. Consider the alternative: BSTR Detach() { BSTR garbage = m_str; ... m_str = NULL; return garbage; } This function is supposed to...
... Yes, this is correct. The alternative could be: BSTR Detach() { BSTR garbage = m_str; ... m_str = NULL; return garbage; } See what I mean? This function...
There is nothing wrong with the code in Detach(), it is simply handing over ownership of the BSTR to whatever is calling it. The calling method now has the...
Hi Its an out parameter for a function. I'm loading string from resource and passing it back. Regards Tarun ... From: Kim Gräsman [mailto:kim@...] Sent:...
Thats what Detach() should do. Releasing the buffer is made by Empty(). Why don't you assign immediately? As in *bstrBuffer = T2W(szData); /Johann ... From:...
... Incidentally, the following is the most efficient way *I* know how to do it (lifted substantially from MSDN)... UINT block = (uid >> 4) + 1; // Compute...
... To be more correct: POINT pt = {GET_X_LPARAM(lParam),GET_Y_LPARAM(lParam)}; if((pt.x == -1) && (pt.y == -1)) { // used keyboard to show menu ... } HWND...
... Sorry. You could try the following: If the rebar is hit, then you could use the RB_HITTEST message to determine the index of the band that was hit. If a...
Hello all, More of an API question than WTL: I am wanting to detect a keypress on a popup menu. I have found that handling the WM_MENUCHAR message works great...
9849
Serhiy Serbin
srs@...
Sep 7, 2004 3:31 pm
Hi, It's question about windows common control and not about WTL. But I hope you will help me. I have a problem. When I create dynamically edit control it has...
"Aaron Hudon" <aaronh@...> wrote in message news:chkk7l+sii3@eGroups.com ... Since you have menu handle, perhaps you can enumerate all items and look for...
If I have a bunch of dialogs like this : class CAboutDlg : public CDialogImpl<CAboutDlg,CAnimateWindow> { }; class CMaterials : public CDialogImpl<CMaterials> ...
Hi ... You don't have a common base class, so you can either add one (eg. an interface) or make your SomeFunction a template function: template< class T > ...
"Eamonn Wallace" <eamonnwallace@...> wrote in message news:092001c494f3$1f3fdfa0$010aa8c0@Broomhall ... Apparently, all your dialog classes need to have...
... ugly ... If the parent's message map has REFLECT_NOTIFICATIONS(), or if the WM_CTLCOLOREDIT message is being explicitly handled by your application, it...
... Create ... dialogs ... Parliament], 'Pray, ... right ... This thread reminded me of a good article in the VC 6.0 MSDN Library. Dale Rogerson's article...
//first i create a toolbar from resource, all buttons are bitmap buttons that doesn't have text HWND hWndToolBar = CreateSimpleToolBarCtrl(m_hWnd, uResID,...
Never mind my last post I've figured out a workable solution. Here it is , stripped of baggage, if anybody has a better idea then I'd love to hear it. Many...
9860
Paul Ranson
paul@...
Sep 8, 2004 9:59 am
Can you not simply write, template< class T > class EditorActions : private ViewRecordListener { public: EditorActions { } void...