jakob.j
jakob.j

Reputation: 963

Windows Phone 8 - take a screenshot

Is there any way to take a screenshot on Windows Phone 8 (or 7.1) programmatically?

For Windows Phone 7/7.1, there is at least an inofficial solution: http://forum.xda-developers.com/showthread.php?t=1006331

But I have no idea what to do to get this functionality in my own app.

Also, I would intend to take screenshots not only of my own app but also of other apps (e.g. timer triggered).

Upvotes: 2

Views: 2902

Answers (3)

Rashad Valliyengal
Rashad Valliyengal

Reputation: 3162

  • You can take a screenshot using your Emulator.
  • When you run your app on Emulator you can see a double arrow button right side of the Emulator.
  • Click on that double arrow button, which ll show another window right side of the Emulator.
  • And Tap on the screenshot tab and capture the screenshot.
  • You can save the screenshot to your local machine.

Upvotes: 0

Jay
Jay

Reputation: 133

You could easily do this on emulator, run your app, and then click double arrow button which pops up another window, and then go to screenshot tab and capture. Or if you have device press Widnows Home and Power simmontaniously.

Upvotes: 0

kutty japan
kutty japan

Reputation: 60

you can take the screen shot in your windows phone 8, by the simultaneous press of the volume button and the window key. or else try this code

var bmp = new WriteableBitmap(lbxDays, new TranslateTransform());
var width = (int)bmp.PixelWidth;
var height = (int)bmp.PixelHeight;
bmp.Render(lbxDays, new TranslateTransform());
using (var ms = new MemoryStream())
 {
 bmp.SaveJpeg(ms, width, height, 0, 100);
 ms.Seek(0, System.IO.SeekOrigin.Begin);
 var lib = new MediaLibrary();
 var dateStr = DateTime.Now.Ticks;
 var picture = lib.SavePicture(string.Format("screenshot"+dateStr+".jpg"), ms);
 var task = new ShareMediaTask();
 task.FilePath = picture.GetPath();
 task.Show();
 }

Upvotes: 3

Related Questions