sunjinbo
sunjinbo

Reputation: 2187

How to keep flashlight light on windows phone 8?

I created an app, it makes camera flashlight light on to simulate real Torch. But once the Lock screen is on, the flashlight can't stay too long, a few seconds later, the light will off. Is there have any way to keep flashlight light on always?

P.S I found some app on Microsoft App Marketplace, they did this.

Upvotes: 1

Views: 298

Answers (1)

Ajay GU
Ajay GU

Reputation: 538

The following code will allow your app to continue to run when the lock screen is activated:

PhoneApplicationService.Current.ApplicationIdleDetectionMode = IdleDetectionMode.Disabled;

MSDN link

Example

Upvotes: 1

Related Questions