windows-10-universal

How to pass default credentials in Windows Authentication

孤街浪徒 提交于 2019-11-29 00:38:20
I'm developing UWP application using C#.net and it has WCF service with Windows Authentication enabled. I struggling to pass default NetworkCredential after consume a service call using Add service reference option. Please find below my examinations. When I pass correct windows authentication credentials, it is working as expected. var service = new ServiceReference.Service1Client(); service.ClientCredentials.Windows.ClientCredential =new NetworkCredential("pradeep","****"); var test = await service.GetDataAsync(1); but, I wanted pass default network credentials while using my service methis

Could not load file or assembly 'Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies

ぐ巨炮叔叔 提交于 2019-11-28 18:40:51
I have a WinJS project that is previously built on Windows 8.1 using VS 2013. Recently I upgraded this project to Universal Windows 10 by creating a blank Javascript Universal windows 10 project and then added all my files from old project. I have Windows Runtime Components and also Class Library for SQLite. I added Universal Windows Runtime Component and Universal Class Library and copied all my files from old project to respective places. Somehow I managed to remove all the build errors. I installed all the required SQLite-net, SQLite for Universal Windows Platform, Newtonsoft, etc. But when

send login data with POST method in a universal app

谁说我不能喝 提交于 2019-11-28 14:12:48
I am working a windows app store,and I am trying to send login and password values,this is my code: try { string user = login.Text; string pass = password.Password; ASCIIEncoding encoding = new ASCIIEncoding(); string postData = "login=" + user + "&mdp=" + pass; byte[] data = encoding.GetBytes(postData); WebRequest request = WebRequest.Create("myURL/login.php"); request.Method = "POST"; request.ContentType = "application/x-www-form-urlencoded"; request.ContentLength = data.Length; Stream stream = request.GetRequestStream(); stream.Write(data, 0, data.Length); stream.Dispose(); WebResponse

How to launch a full-trust (desktop bridge) app from UWP with arbitrary parameters

三世轮回 提交于 2019-11-28 11:32:46
Is it possible for a UWP app to launch its Desktop Bridge (full-trust application component) with arbitrary command-line arguments? I see the ability to specify "argument groups" (see https://docs.microsoft.com/en-us/uwp/api/Windows.ApplicationModel.FullTrustProcessLauncher ), but it looks like that only supports using a predefined ParameterGroup . I need to launch a UWP with programmatically-determined (at launch time) arbitrary command-line arguments. Is this possible, and if so, how? No this is not possible today. One quick way to accomplish the scenario is to have the UWP write the command

UWP equivalent function to FindAncestor in uwp

不羁的心 提交于 2019-11-28 10:10:00
I have a list of orders and when the order status is Cancelled , I want to blink the text. So far, my code works. However, sometimes it will throws exception: WinRT information: Cannot resolve TargetName lblOrderStatus For some reason lblOrderStatus can be found. So, I want to use "FindAncestor", but FindAncestor doesn't exists in UWP. Is there any equivalent function to FindAncestor in uwp? Here is my code: <ItemsControl x:Name="Orders" Grid.Row="1" Background="Transparent"> ... ... ... <ItemsControl.ItemTemplate> <DataTemplate> <Grid> ... ... ... <Viewbox Grid.Column="3" StretchDirection=

Loading Html file in WebView in xaml in UWP from app data local folder

女生的网名这么多〃 提交于 2019-11-28 09:19:10
I have a requirement where I need to load an html file from app data folder in xaml WebView in UWP. Html file is also referencing different Js files in another folder ("99/js/"). Any one with UWP knowledge guide me. Thanks in advance I am using following code, Browser is my WebView. var Uri = new Uri("ms-appdata:///Local/Downloads/99/index.html"); Browser.Navigate(Uri); My folder structure in 99 folder is: udapte I am trying load html file in offline to WebView which is not loading same html file is loading with server url. To load the index.html in WebView while offline, you need to make sure

Windows 10 Mobile Error: DEP6200

假装没事ソ 提交于 2019-11-28 08:09:05
问题 I am trying to deploy a Windows 10 app to a Lumia 635 running 10.0.10586.11 and I get this error: Error : DEP6100 : The following unexpected error occurred during bootstrapping stage 'Connecting to the device 'DEVICE GUID'.': SEHException - External component has thrown an exception. Error : DEP6200 : Bootstrapping 'Device' failed. Device cannot be found. The data necessary to complete this operation is not yet available. Unlike most, I am capable of deploying to an Emulator, just not the

How to access registry key in a UWP app?

隐身守侯 提交于 2019-11-28 00:32:42
I would like to access windows10 registry key by a UWP app. key as: \HKEY_LOCAL_MACHINE\SOFTWARE\MyCompanyName\MyName I can not find any function call to accomplish it. Please indicate me How to do it? Thank you, Paula You can read registry values from a Win32 runFullTrust background process launched from a UWP application, and you can write values in the HKEY_LOCAL_MACHINE hive from an "elevated" Win32 application launched from that runFullTrust process. These techniques are powerful and using them in a UWP app deployed from the Windows Store requires special scrutiny and permission from

how to read a text file in windows universal app

天大地大妈咪最大 提交于 2019-11-27 23:14:52
I am trying to read a text file named thedata.txt that has a list of words that I want to use in a hangman game. I have tried different ways, but I can't figure out where the file gets placed, if at all when the app runs. I added the file to my project, and I have tried setting the build properties to content, and then embedded resource, but can't find the file. I have made a Windows 10 universal app project. The code I tried looks like this: Stream stream = this.GetType().GetTypeInfo().Assembly.GetManifestResourceStream("thedata.txt"); using (StreamReader inputStream = new StreamReader(stream

How to get unique Device IDs on Windows 10 Anniversary Update

筅森魡賤 提交于 2019-11-27 22:33:29
Previous iterations of Windows 10 have the HardwareToken API (aka ASHWID) to get a unique identifier for the device, but it had several drawbacks: It was only available on Desktop and Mobile platforms, which required you to add an Extension SDK to your project (and wasn't available on HoloLens or other platforms) On the PC, the value could "drift" as hardware changed (even just plugging a laptop into a docking station would change the ID), so you needed complex backend logic to correlate device IDs The value was specific to a single app, and couldn't be shared across apps by the same publisher