views:

82

answers:

2

Hi, how can I disable the start menu! Or completely shut down the entire "explorer" in Windows Windows Mobile 6.1, so that users can not go out of my program.

I have try http://pastebin.com/yz6WN6xa , but then Windows Mobile 6.1 hang.

A: 

I think the closest you can get is setting ControlBox = false and having no menu, i.e. Menu = null in your Form. It depends on what version your client is running.. This will have more effect on Windows CE 6.5.

Form.ControlBox disables the "X" button and having a null Form.Menu makes your application "full screen", as no buttons will show.

Patrick
this I have done:) The problem is that when I focus on another control jumps up the start menu up.
sv88erik
@sv88erik: What other control do you focus on? Does that control (or dialog) use a menu?
Patrick
@ Patrick: It has no menu. When I focus on one text box pops up the start menu.
sv88erik
@Patrick: By the way, the textbox is inside a user control located inside the dialog. The reason for this is that I have many user controls.
sv88erik
@sv88erik: Ah yes, of course. Unfortunately I can't help you any further. As paxdiablo commented on, it's a bit intrusive to the users to completely disable the start menu, so it *should* not be easy to accomplish. :-/
Patrick
+1  A: 

I found out about it myself!

Public Class TaskBoard
<DllImport("coredll.dll")> _
Public Shared Function FindWindow(ByVal lpClassName As String, ByVal lpWindowName As String) As IntPtr
End Function

<DllImport("coredll.dll")> _
Public Shared Function ShowWindow(ByVal hWnd As IntPtr, ByVal visible As Integer) As IntPtr
End Function

End Class

Then I call the class as follows:

TaskBoard.ShowWindow(TaskBoard.FindWindow("HHTaskBar", Nothing), 0)
sv88erik