locked
how to hide the owner Information page RRS feed

  • Question

  • i am creating a simple alarm clock app. When the alarm goes off, the phone is in the suspend state. so i wake up the phone and then i give my form the focus by activating.
    the problem i am having is the "Owner Information Screen" shows up and my form doesnt get focus. if i disable displaying Owner Information, then my form is able to get focus when the device wakes up from suspend state.

    here is a code i am using:
    private void SetOffAlarm()
            {
                int wakeUp = Power.SetSystemPowerState(null, (int)Power.PowerState.POWER_STATE_ON, (int)Power.PowerRequirement.POWER_FORCE);
                Thread.Sleep(2000);
                this.Activate();
                Thread.Sleep(1000);
                PlayWave();
                btnStop.Visible = true;    
                           
            }

    any help would be greatly appreciated.

    Thanks
    Faisal
    Thursday, August 27, 2009 8:39 PM

Answers

  • Ok,
    Check the owner info dialog creation flags using remote spy and apply
    same flags for your window and before show the your window get the handle of owner info dialog handle
    and hide or move to different position,
    Let me know if you need further help/code.

    Siva.
    • Proposed as answer by GSiva Saturday, August 29, 2009 8:35 AM
    • Marked as answer by ZHE ZHAO Thursday, September 3, 2009 1:24 AM
    Saturday, August 29, 2009 8:35 AM
  • Ok ,
    Please follow these steps,
       

      1) Open owner information dialog in your device /emulator
       2) fire remote spy and connect to your device/emulator
      3) check owner info dialog in remote spy mostly its under  setting.
      4) get the Style value from the SPY and create your dialog with same style
      5)  call - SetForegroundWindow((HWND)(((ULONG) yourwindow handle) | 0x01) )


    Hope this will help you


    Siva.

     
    • Marked as answer by ZHE ZHAO Thursday, September 3, 2009 1:24 AM
    Tuesday, September 1, 2009 7:11 AM

All replies

  • Ok,
    Check the owner info dialog creation flags using remote spy and apply
    same flags for your window and before show the your window get the handle of owner info dialog handle
    and hide or move to different position,
    Let me know if you need further help/code.

    Siva.
    • Proposed as answer by GSiva Saturday, August 29, 2009 8:35 AM
    • Marked as answer by ZHE ZHAO Thursday, September 3, 2009 1:24 AM
    Saturday, August 29, 2009 8:35 AM
  • GSiva

    Thanks for the reply but i would need more help with this. i am fairly new to windows/mobile programming.

    Thanks
    Faisal
    Monday, August 31, 2009 3:51 PM
  • Ok ,
    Please follow these steps,
       

      1) Open owner information dialog in your device /emulator
       2) fire remote spy and connect to your device/emulator
      3) check owner info dialog in remote spy mostly its under  setting.
      4) get the Style value from the SPY and create your dialog with same style
      5)  call - SetForegroundWindow((HWND)(((ULONG) yourwindow handle) | 0x01) )


    Hope this will help you


    Siva.

     
    • Marked as answer by ZHE ZHAO Thursday, September 3, 2009 1:24 AM
    Tuesday, September 1, 2009 7:11 AM