🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.web
Article #861

Re: Detecting whether a web site contains frame

#861
From: Remy Lebeau (TeamB)
Date: Fri, 13 Jan 2006 18:01
24 lines
1833 bytes
"Mehmet Caner" <mcaner40@hotmail.com> wrote in message
news:43c7e531$1@newsgroups.borland.com...

> But I can not detect whether the page contains frame or not.

That is because you are not taking into account that the
DISPID_DOCUMENTCOMPLETE event is triggered separately for each individual
frame.  Your code is assuming that when the event is triggered, it is only
triggered for the top-level document that contains the frames inside of it.
That is not always the case.  When the event is triggered for a particular
frame, your code is then checking if that document has frames of its own.
If it does not, then you code is ignoring the frame that triggered the
event.

> if(Doc->get_frames(&Frames)==S_OK)
>
> return always S_OK whether the page contains frame or not.

As it should be.  The return value indicates whether the collection itself
was retreived.  Not whether the collection was filled with anything.


Gambit
Technical Details
Message-ID: <43c7ea46$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news4.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <43c7e531$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: feeec,1c8ab6266d6ff57f
X-Google-Attributes: gidfeeec,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com>
Newsgroups: borland.public.cppbuilder.internet.web
References: <43c7e531$1@newsgroups.borland.com>
Subject: Re: Detecting whether a web site contains frame
Date: Fri, 13 Jan 2006 10:01:10 -0800
Lines: 26
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
NNTP-Posting-Host: 68.69.17.41
Message-ID: <43c7ea46$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1137175110 68.69.17.41 (13 Jan 2006 09:58:30 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news4.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail