Click here to Skip to main content
15,914,396 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Illegal call of Non Static Member Function Pin
Amit Agarrwal29-Jun-06 23:24
Amit Agarrwal29-Jun-06 23:24 
GeneralRe: Illegal call of Non Static Member Function Pin
Mattias Paulsson3-Jul-06 22:44
Mattias Paulsson3-Jul-06 22:44 
AnswerRe: Illegal call of Non Static Member Function Pin
Cedric Moonen29-Jun-06 22:07
Cedric Moonen29-Jun-06 22:07 
GeneralRe: Illegal call of Non Static Member Function Pin
Amit Agarrwal29-Jun-06 23:25
Amit Agarrwal29-Jun-06 23:25 
GeneralRe: Illegal call of Non Static Member Function Pin
Cedric Moonen29-Jun-06 23:33
Cedric Moonen29-Jun-06 23:33 
Questionhow to change MFC icon?? Pin
mimimimilaw29-Jun-06 21:55
mimimimilaw29-Jun-06 21:55 
AnswerRe: how to change MFC icon?? [modified] Pin
Sarath C29-Jun-06 22:20
Sarath C29-Jun-06 22:20 
GeneralRe: how to change MFC icon?? Pin
mimimimilaw29-Jun-06 22:27
mimimimilaw29-Jun-06 22:27 
QuestionDirectx8 document Pin
blue_rabbit29-Jun-06 21:49
blue_rabbit29-Jun-06 21:49 
QuestionAdvice on Global Hook Pin
P Gibson29-Jun-06 21:41
P Gibson29-Jun-06 21:41 
QuestionContext menu Pin
_anil_29-Jun-06 21:41
_anil_29-Jun-06 21:41 
AnswerRe: Context menu Pin
Michael Dunn29-Jun-06 21:47
sitebuilderMichael Dunn29-Jun-06 21:47 
GeneralRe: Context menu Pin
_anil_29-Jun-06 22:37
_anil_29-Jun-06 22:37 
AnswerRe: Context menu Pin
RockyJames29-Jun-06 22:31
RockyJames29-Jun-06 22:31 
Questionwhy IHTMLElementCollection can not "Item" all the Items? Pin
Tcpip200529-Jun-06 21:27
Tcpip200529-Jun-06 21:27 
void CParseView::GetEmbeds()
{
	IHTMLElement* pDocElem;
	IHTMLElementCollection* pElemCollections;
	
	IHTMLDocument2 * pHTMLDoc2 = NULL;
	pHTMLDoc2 = (IHTMLDocument2*)(this->GetHtmlDocument());
	pHTMLDoc2->get_all(&pElemCollections);
	
	COleVariant varName;
	varName = SysAllocString(L"OBJECT");
	
	IDispatch* spDispEmbed;
	
	VARIANT name;
	name.vt = VT_I4;
	
	pElemCollections->tags(varName, &spDispEmbed);
	
	IHTMLElementCollection* spCollectEmbed;
	spDispEmbed->QueryInterface(IID_IHTMLElementCollection, (void**)&spCollectEmbed);
	if (spCollectEmbed)
	{
		long lLen;
		spCollectEmbed->get_length(&lLen);
		for (long i = 0; i < lLen; i++)
		{
			IDispatch* pItem;
			
			name.lVal = i;
			spCollectEmbed->item(NULL, name, &pItem);
						
			IHTMLElement* spElement;
			pItem->QueryInterface(IID_IHTMLElement, (void**)&spElement);
						
			if(pItem)
				pItem->Release();
			
			if(spElement)
				spElement->Release();
		}
	}
	if(pHTMLDoc2)
		pHTMLDoc2->Release();
}


use the code, I got the length:lLen=4;but I can only fetch the first two Items,when i=2,pItem got a NULL. How could this happen?
AnswerRe: why IHTMLElementCollection can not "Item" all the Items? Pin
Viorel.29-Jun-06 21:43
Viorel.29-Jun-06 21:43 
GeneralRe: why IHTMLElementCollection can not "Item" all the Items? Pin
Tcpip200529-Jun-06 22:22
Tcpip200529-Jun-06 22:22 
AnswerRe: why IHTMLElementCollection can not "Item" all the Items? Pin
Hamid_RT29-Jun-06 21:58
Hamid_RT29-Jun-06 21:58 
QuestionHow to mask the bitmaps?? Pin
Laxman Auti29-Jun-06 21:19
Laxman Auti29-Jun-06 21:19 
AnswerRe: How to mask the bitmaps?? Pin
Don Box29-Jun-06 21:33
Don Box29-Jun-06 21:33 
GeneralRe: How to mask the bitmaps?? Pin
Laxman Auti29-Jun-06 21:56
Laxman Auti29-Jun-06 21:56 
QuestionIs that madatory to close the socket when error? [modified] Pin
raserove29-Jun-06 20:46
raserove29-Jun-06 20:46 
QuestionProblem when using right click to select an item in CTreeCtrl. Pin
followait29-Jun-06 20:41
followait29-Jun-06 20:41 
AnswerRe: Problem when using right click to select an item in CTreeCtrl. Pin
cje30-Jun-06 5:30
cje30-Jun-06 5:30 
QuestionHow can I register the new fonts with OS ? Pin
Sameer_Thakur29-Jun-06 20:34
Sameer_Thakur29-Jun-06 20:34 

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.