Click here to Skip to main content
15,920,111 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Double linked list is overwriting string items Pin
Yustme13-Apr-07 2:16
Yustme13-Apr-07 2:16 
QuestionNew to VS 2005 - How do I switch between C++ to C#? Pin
huehue12-Apr-07 8:54
huehue12-Apr-07 8:54 
AnswerRe: New to VS 2005 - How do I switch between C++ to C#? Pin
led mike12-Apr-07 9:23
led mike12-Apr-07 9:23 
AnswerRe: New to VS 2005 - How do I switch between C++ to C#? Pin
huehue12-Apr-07 10:45
huehue12-Apr-07 10:45 
AnswerRe: New to VS 2005 - How do I switch between C++ to C#? Pin
George L. Jackson12-Apr-07 11:15
George L. Jackson12-Apr-07 11:15 
GeneralRe: New to VS 2005 - How do I switch between C++ to C#? Pin
huehue12-Apr-07 11:29
huehue12-Apr-07 11:29 
GeneralRe: New to VS 2005 - How do I switch between C++ to C#? Pin
George L. Jackson12-Apr-07 11:42
George L. Jackson12-Apr-07 11:42 
QuestionHow To Load Google Toolbar For Dialog Pin
MyNothing12-Apr-07 7:10
MyNothing12-Apr-07 7:10 
How To Load Google Toolbar For Dialog??

Google Toolbar ClsID:{2318C2B1-4965-11d4-9B18-009027A5CD4F}

Code:
bool CShowToolbarDlg::LoadIEToolbar( CString strCLSID )
{	
	CLSID clsid;

	WCHAR wsz[MAX_PATH]; 
	::MultiByteToWideChar(CP_ACP, 0, strCLSID, -1, wsz, MAX_PATH);

	HRESULT hr = CLSIDFromString(wsz, &clsid);	
	if ( hr != NOERROR )	
		return false;	
	
	::CoInitialize (NULL);
	IUnknown* puk;
	hr = ::CoCreateInstance(clsid, NULL, CLSCTX_INPROC_SERVER, IID_IUnknown, (void**)&puk);
	
	if (FAILED(hr))		
		return false;

	IDeskBand *pdb;	
	hr = puk->QueryInterface(IID_IDeskBand, (void**)&pdb);
	
	HWND hBand;
	if (SUCCEEDED(hr))		
	{     
		pdb->GetWindow(&hBand);	
		
		if(hBand == 0)
			return false;
			
		CWnd *pWnd = CWnd::FromHandle(hBand);	
	}		
	
	m_pReBar   =   new   CReBar();   
	m_pReBar->Create(this);   
	
	CWnd *pWnd = CWnd::FromHandle(hBand);
	
	if(pWnd==NULL) return false;
	
	m_pReBar->AddBar(pWnd,NULL,NULL, RBBS_BREAK);		
				
	REBARBANDINFO rbbi;		
	rbbi.cbSize = sizeof(rbbi);			
	rbbi.fMask = RBBIM_CHILDSIZE | RBBIM_IDEALSIZE | RBBIM_SIZE;			
	rbbi.cxMinChild = 0;			
	rbbi.cyMinChild = 10;			
	rbbi.cx = rbbi.cxIdeal = 250;			
	UINT nCount = m_pReBar->GetReBarCtrl().GetBandCount();			
	m_pReBar->GetReBarCtrl().SetBandInfo(nCount-1, &rbbi); 			
	
	return true;
	
}


Error:
pdb->GetWindow(&hBand);
if(hBand == 0)
return false;

Why hBand is NULL??
AnswerRe: How To Load Google Toolbar For Dialog Pin
Reagan Conservative12-Apr-07 9:35
Reagan Conservative12-Apr-07 9:35 
Questioninstalling a program i've made Pin
Tully200312-Apr-07 6:45
Tully200312-Apr-07 6:45 
AnswerRe: installing a program i've made Pin
Mark Salsbery12-Apr-07 7:12
Mark Salsbery12-Apr-07 7:12 
AnswerRe: installing a program i've made Pin
Maximilien12-Apr-07 8:32
Maximilien12-Apr-07 8:32 
AnswerRe: installing a program i've made Pin
Ravi Bhavnani12-Apr-07 11:36
professionalRavi Bhavnani12-Apr-07 11:36 
AnswerRe: installing a program i've made Pin
sanket.patel12-Apr-07 16:03
sanket.patel12-Apr-07 16:03 
QuestionTrying to understand VS AddIns Pin
dburns12-Apr-07 6:28
dburns12-Apr-07 6:28 
QuestionIs possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
marcelse12-Apr-07 4:37
marcelse12-Apr-07 4:37 
AnswerRe: Is possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
John R. Shaw12-Apr-07 4:54
John R. Shaw12-Apr-07 4:54 
GeneralRe: Is possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
marcelse12-Apr-07 5:07
marcelse12-Apr-07 5:07 
GeneralRe: Is possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
John R. Shaw12-Apr-07 5:35
John R. Shaw12-Apr-07 5:35 
GeneralRe: Is possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
Russell'12-Apr-07 10:54
Russell'12-Apr-07 10:54 
GeneralRe: Is possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
Stephen Hewitt12-Apr-07 14:05
Stephen Hewitt12-Apr-07 14:05 
AnswerRe: Is possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
Nemanja Trifunovic12-Apr-07 11:08
Nemanja Trifunovic12-Apr-07 11:08 
AnswerRe: Is possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
sanket.patel12-Apr-07 16:13
sanket.patel12-Apr-07 16:13 
GeneralRe: Is possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
marcelse13-Apr-07 2:23
marcelse13-Apr-07 2:23 
GeneralRe: Is possible to allocate strictly physical mem.(RAM) instead of virtual (page file) Pin
marcelse13-Apr-07 9:49
marcelse13-Apr-07 9:49 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.