Re: bringing Pocket Internet Explorer (PIE) to foreground

From: Peter Foot [MVP] (feedback_at_no-spam.inthehand.com)
Date: 11/06/04


Date: Sat, 6 Nov 2004 17:31:26 -0000

Since the first argument of FindWindow is the classname and the second is
the window title try

int h = FindWindow(null, "Internet Explorer");

Peter

-- 
Peter Foot
Windows Embedded MVP
www.inthehand.com | www.opennetcf.org
"Rich" <Rich@discussions.microsoft.com> wrote in message 
news:71A7F7F6-CAE5-45C2-B17C-ECACC30469E0@microsoft.com...
> Hopefully a trivial question -
> I have a C# PocketPC 2003 Windows Forms application running under ARMv4.
> I want to have the application put itself in the background and bring PIE 
> to
> the foreground. PIE is already loading, and can be seen in "Running 
> Programs".
>
> I tried the famous code example where I substituted out "HHTaskBar" for 
> PIE
>
> static public void showTaskBar ()
> {
> int h = FindWindow ("HHTaskBar", "");
> ShowWindow (h, SW_SHOW);
> }
>
>
> [DllImport("coredll.dll")]
> public static extern int FindWindow (string lpClassName, string
> lpWindowName);
> private const int SW_HIDE = 0x0000;
> private const int SW_SHOW = 0x0001;
>
> [DllImport("coredll.dll")]
> public static extern int ShowWindow (int hwnd, int nTaskShow);
>
> [DllImport("coredll.dll")]
> public static extern int MoveWindow (IntPtr hwnd, int X, int Y, int
> nWidth, int nHeight, bool bRepaint);
> }
>
> My code for show is -
>  static public void showPIE ()
>    {
>      int h = FindWindow ("IEFrame", "");
>      // int h = FindWindow ("iexplore", "");
>      // int h = FindWindow ("Internet Explorer", "");
>      ShowWindow (h, SW_SHOW);
>    }
>
> However, PIE is not brought to the foreground.
>
> As the commented lines in "showPIE" hint, I tried various names for PIE -
>  "Internet Explorer" appears in the list of "Running Programs",
>  "iexplore.exe" is the name of the executable in the PocketPC Windows
> directory,
>  and I saw a web posting that hinted that "IEFrame" might work.
>
> In any of the three cases, the integer h in "showPIE" is bound to "0".
>
> What do I need to change?
>
> Also - No offence intended, but I have a mild preference *not* to have to
> use a 3rd-party library such as opennetcf.org 


Relevant Pages

  • Re: LogonUser()
    ... // This sample can be run only on Windows XP. ... String lpszPassword, ... int dwLogonType, int dwLogonProvider, ref IntPtr phToken); ... private unsafe static extern int FormatMessage(int dwFlags, ref IntPtr ...
    (microsoft.public.dotnet.security)
  • bringing Pocket Internet Explorer (PIE) to foreground
    ... I have a C# PocketPC 2003 Windows Forms application running under ARMv4. ... PIE is already loading, and can be seen in "Running Programs". ... public static extern int FindWindow (string lpClassName, ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: bringing Pocket Internet Explorer (PIE) to foreground
    ... Peter Foot ... the PIE window did not come to the foreground on the ASUS ... >> Windows Embedded MVP ... >>> public static extern int FindWindow (string lpClassName, ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: What are Coredll.dll methods of CE in XP Embedded?
    ... > coredll.dll of Windows CE in Windows XP embedded? ... > phoneBookPath,byterasDialParam, int NotifierType,int notifier,ref int ... > public static extern uint RasHangUp; ...
    (microsoft.public.windowsxp.embedded)
  • Re: W2k/XP hangs with "TAB BS BS" on console
    ... >> console compiler) was executed: ... Now in this function we can see if we disassemble that 'int 2Eh' is called, ... _KiSystemService copies the parameters from the Ring 3 stack which EDX ... NT has this problem in all service packs, Windows 2000 has it and XP seems ...
    (NT-Bugtraq)