windows-store-apps

How to adjust Brightness and Contrast of an image using a slider?

为君一笑 提交于 2020-01-09 11:19:23
问题 I have an image and i want to adjust its brightness and contrast through a slider in xaml. I don't know where to start.Any help would be appreciated. I am trying to implement this public WriteableBitmap ChangeBrightness(WriteableBitmap inputBitmap, double brightnessValue ) { double Value = brightnessValue; var inputPixels = inputBitmap.Pixels; for (int i = 0; i < inputPixels.Length; i++) { // Extract color components var c = inputBitmap.Pixels[i]; var a = (byte)(c >> 24); var r = (byte)(c >>

Launching a Windows 10 Store app from C# executable

走远了吗. 提交于 2020-01-07 05:23:09
问题 So here's the gist of my problem: I have a keyboard where I can assign macros and/or launch programs from. I want to include a couple Win10 and Steam applications in that list. So I opted to build an executable "launcher", so to speak. The code is simplistic in nature. I got Steam url's to work by placing the steam url into Process.Start("steam://rungameid/#####"). I cannot, however, figure out how to get Win10 apps to work. Here's my class: public partial class Form1 : Form { public Form1()

Adcontrol does not show ads with pub center App id and Unit id

拜拜、爱过 提交于 2020-01-06 20:25:11
问题 I have an Adcontrol which works fine with test values given by Msdn but does not shows ads with actual values.(Windows Store App) 回答1: This could be a perfectly normal behaviour if there is no ad to display. You can suscribe to the ErrorOccured event of the AdControl and check the Error property to confirm that by seeing a "No fill" message. 来源: https://stackoverflow.com/questions/34148828/adcontrol-does-not-show-ads-with-pub-center-app-id-and-unit-id

WebRequest.GetRequestStreamAsync() method timesout each time for MNS access token

这一生的挚爱 提交于 2020-01-06 14:54:38
问题 I am trying to get the access token from MNS for Push notifications and the WebRequest.GetRequestStreamAsync() method timesout each time. Any suggestions? Reference: http://msdn.microsoft.com/en-us/library/windows/apps/hh913756.aspx Below is the code I use HttpWebRequest webRequest = (HttpWebRequest)HttpWebRequest.Create("https://login.live.com/accesstoken.srf"); webRequest.Method = "POST"; webRequest.ContentType = "application/x-www-form-urlencoded"; string postString = String.Format("grant

Windows Store application + Simulation in MSVS 2013

时间秒杀一切 提交于 2020-01-06 14:40:52
问题 First, sorry for my English it`s not my native language. Second I start to learn tutorial for create Windows Store application. In the end of Part 3 we were invited to use Visual Studio Simulator. But when I run it I take an error: Windows Simulator needs your credentials. Please lock this computerm then unlock it using your current password and run the Windows Simulator again. To lock your computer, press CTRL-ALT-DEL and the press Enter I found some reference http://support.microsoft.com/kb

Local file storage during development of a Windows Store App

半世苍凉 提交于 2020-01-06 13:53:34
问题 So I'm getting started in windows store apps. It is also my first experience with Visual Studio. Windows 8.1 for that matter, too :P I'm trying to figure out how local file storage works during the dev phase of this project. I understand the concept of how the appdata directory and the application install directory interact with the app once it is published and installed on a client's PC. This SO answer gives a good overview of how it is supposed to work. However, I can't figure out how,

Choosing a certificate for a Windows Store application via the package.appxmanifest

我是研究僧i 提交于 2020-01-06 02:12:49
问题 So that an WinRT application can be internally distributed via Intune I need to attach a certificate as per http://msdn.microsoft.com/en-us/library/windows/apps/br230260(v=vs.110).aspx I go to the package.appxmanifest screen, click choose certificate - > configure certificate - > select from file. I double click on the relevant certificate, and type the password. I then get the error message "The Manifest Designer could not import the certificate. The certificate you selected is not valid for

ProgressBar button doesn't show while service call in windows store app

ε祈祈猫儿з 提交于 2020-01-05 17:30:11
问题 I want to show ProgressBar when service call made. Product.xml <ProgressBar Name="loading1" Visibility="Collapsed" IsIndeterminate="True" HorizontalAlignment="Left" Height="50" Width="535" VerticalAlignment="Center" Background="White" Grid.Row="1" Margin="0,311,0,310"/> Product.xml.cs loading.Visibility = Visibility.Visible; //loading start getAllProductDetails(); //contain service call and bind data in list loading.Visibility = Visibility.Collapsed; //loading finish Loading should start

Can a metro app open the default browser without opening a page?

戏子无情 提交于 2020-01-05 04:57:50
问题 On button click I want to open the default metro browser (usually IE) without opening a new tab/page, just open the browser, If it is already running then just switch to it as it is to it's current state. Is there a way to do that? 回答1: This is just something to try, and may or may not work in your scenario: If you know the url that is open in the browser, your Windows Store app could launch that same url with the launcher. In my app, when I launch the same url multiple times, IE will pop up

How to subscribe to events raised within a Windows Runtime Component in C++/CX?

☆樱花仙子☆ 提交于 2020-01-05 02:54:11
问题 I have an class in a Windows Runtime Component (written in C#) that raises events. I cannot work out how to subscribe to these events in a C++/CX app that references the component. The C# code (in the Windows Runtime Component): public sealed class Messenger { private EventRegistrationTokenTable<EventHandler<MessageReceivedEventArgs>> messageReceivedTokenTable; public event EventHandler<MessageReceivedEventArgs> MessageReceived { add { return EventRegistrationTokenTable<EventHandler