figuerres said:
NotSoTragicHero said:
*snip*

in my app i found that you must do some things in the right order and it's not as simple as it could be.

 

here is part of the code, i use the OpenNetCF for part of how it does is't thing.

 

using System; using System.Text;
 using OpenNETCF.Win32; 
using System.Windows.Forms; 
namespace PocketN { 
public class NoTaskBar { 
public static void Hide(Form F) {
 F.Capture = true;
 Win32Window hwnd = Win32Window.GetCapture();
 F.Capture = false;
 hwnd.ExtendedStyle |= WS_EX.NOANIMATION;
 } 
private const uint TOPFULL = 0x20000008; 
private const uint TOPFULLNOICON = 0x24000008; 
public static void FullScreen(Form F, bool TaskIcon) { 
F.SuspendLayout(); F.Capture = true; 
Win32Window hwnd = Win32Window.GetCapture(); 
F.Capture = false; F.WindowState = FormWindowState.Normal;
 if (Program.FullScreen) {
 // full 
if ((Program.CurrentPlatform == Platforms.Casio) && (Program.Taskbar.TaskBarVisible)) { 
Program.Taskbar.HideTaskBar(); 
} 
if (Program.CurrentPlatform != Platforms.Casio) {
 if (!TaskIcon) { 
hwnd.ExtendedStyle = (WS_EX)TOPFULLNOICON; 
} else { 
hwnd.ExtendedStyle = (WS_EX)TOPFULL; 
} 
F.Top = 28; F.Left = 0;
 F.Width = Screen.PrimaryScreen.WorkingArea.Width - 6;
 F.Height = Screen.PrimaryScreen.WorkingArea.Height - 6;
 } else {
 if (!TaskIcon) {
 hwnd.ExtendedStyle |= WS_EX.NOANIMATION; 
} else { 
hwnd.ExtendedStyle = WS_EX.NONE; 
}
 F.Top = 0; 
F.Left = 0;
 F.Width = Screen.PrimaryScreen.Bounds.Width;
 F.Height = Screen.PrimaryScreen.Bounds.Height;
 }
 } else { 
// normal 
if ((Program.CurrentPlatform == Platforms.Casio) && (!Program.Taskbar.TaskBarVisible)) {
 Program.Taskbar.ShowTaskBar(); 
}
 if (!TaskIcon) { 
hwnd.ExtendedStyle |= WS_EX.NOANIMATION;
 } else {
 hwnd.ExtendedStyle = WS_EX.NONE; 
} 
if (Program.CurrentPlatform == Platforms.Casio) { 
F.Top = 0; F.Left = 0; F.Width = Screen.PrimaryScreen.Bounds.Width;
 F.Height = Screen.PrimaryScreen.WorkingArea.Height - 3; 
} else {
 F.Top = 28;
 F.Left = 0; 
F.Width = Screen.PrimaryScreen.WorkingArea.Width - 6; 
F.Height = Screen.PrimaryScreen.WorkingArea.Height - 6; 
} 
}
 F.ResumeLayout(); 
} 
} 
}
 

 

Insert Code Block SUCKS!!! it totaly hosed the formatting!

Thanks bud!  We've hacked it for now, (doing a lot of invalidating  Perplexed ), but we'll probably have to come back to this soon when it comes to deployment time.  I'll take note!