Click here to Skip to main content
Rate this: bad
Please Sign up or sign in to vote.
I have already made my metro app based on PC security and its working fine.
I want to start this metro app on Windows Startup, for that i have made a Windows Service so that it can start my metro app.
Problem : How to start a metro app from Windows Service ?
I have googled it alot but couldn't find any solution working for me..
Any change shouldd be done in my metro app so that it can start from other process ??
I have tried till Now :
I have given "redhawk" as my metro app's protocol name.
And the contents of
is as follows :
start "" "redhawk:"

Note : The 2nd method starts my metro app but it stucks on the splash screen. Should i change something in my metro app to avoid this ??
I have also read about OnActivated() event but couldn't apply it successfully..
Please Help Me As Soon As You Can... Thanks in advance...
Posted 21-Mar-13 22:24pm

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

I don't believe this is possible.  Every action a Windows 8 application takes must be made by user interaction, and so starting it automatically would be against that rule.  You should, however, be able to add a background task that can gather data in the background while your app isn't running.  Have you considered that?
here's a great sample that shows how to implement a background agent, in JS, C#, VB, and C++:
Vivek-The Geek at 25-Mar-13 10:32am
Thanks for the reply..
yes i know about the background task, but actually i am trying to authenticate the user from my metro app therefore it can't be done by background task. I need some user interaction to authenticate the user.
in fact i wanted my metro app to be launched at the windows login time but as its not possible, i am trying to authenticate the user after windows login.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 520
1 Maciej Los 205
2 Suvendu Shekhar Giri 159
3 Peter Leow 140
4 Kornfeld Eliyahu Peter 133
0 Sergey Alexandrovich Kryukov 9,623
1 OriginalGriff 8,895
2 Peter Leow 5,044
3 Kornfeld Eliyahu Peter 3,333
4 Maciej Los 2,561

Advertise | Privacy | Mobile
Web04 | 2.8.150327.1 | Last Updated 25 Mar 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100