Article View: borland.public.cppbuilder.nativeapi
Article #8696Re: IE is WindowActive or not?
From: nicolasr
Date: Mon, 27 Sep 2004 20:27
Date: Mon, 27 Sep 2004 20:27
45 lines
1913 bytes
1913 bytes
I think there's a typo in your code. You forgot the brackets for
GetActiveWindow.
Try this:
{
char wClass[255];
GetClassName(GetActiveWindow(), wClass, sizeof(wClass));
if (wClass == "IEFrame")
{
// Continue...
}
}
Nick
> Thanks Nicolasr,
>
> {
> char wClass[255];
> GetClassName(GetActiveWindow, wClass, sizeof(wClass));
> if (wClass == "IEFrame")
> // Continue...
> }
>
> Error!
> Retirn me ASCII character!
> Safari
>
> "nicolasr" <nicolasrNOSPAMATSIGNgmx.net> wrote in message
> news:4150d293@newsgroups.borland.com...
> | Hi,
> |
> | I think you should do it the other way around:
> |
> | Get the active window, then get its class name
> | via GetClassName() and check whether this
> | is "IEFrame".
> | (There may be more than one IEFrame open
> | and FindWindow will maybe not return the active
> | one first)
> |
> | hth,
> | Nick
>
>
Technical Details
Message-ID:
<415877c0$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!zen.net.uk!dedekind.zen.co.uk!news.zanker.org!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<4150d030@newsgroups.borland.com> <4150d293@newsgroups.borland.com> <41574660@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,e705c536883f0885 X-Google-Attributes: gid10cc67,public X-Google-Language: ENGLISH,ASCII-7-bit From: "nicolasr" <nicolasrNOSPAMATSIGNgmx.net> Newsgroups: borland.public.cppbuilder.nativeapi References: <4150d030@newsgroups.borland.com> <4150d293@newsgroups.borland.com> <41574660@newsgroups.borland.com> Subject: Re: IE is WindowActive or not? Date: Mon, 27 Sep 2004 22:27:44 +0200 Lines: 47 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.2180 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 X-RFC2646: Format=Flowed; Original NNTP-Posting-Host: 80.133.173.64 Message-ID: <415877c0$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1096316864 80.133.173.64 (27 Sep 2004 13:27:44 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!zen.net.uk!dedekind.zen.co.uk!news.zanker.org!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail