Minimize instead of Exit in Windows Phone Silverlight 8.1 App - silverlight

I am developing a Windows Phone Silverlight 8.1 App. Whenever the user is pressing BACK Key, it should Minimize/Close/Hide the App instead of Exiting/Quiting.
I mean, how to send the application to background instead of quiting on pressing BACK Key?
How to achieve this?

By merely upgrading an app from 8.0 to 8.1 you get this behavior. This was a change since 8.0. See the documentation under "In-App navigation" here: http://msdn.microsoft.com/en-us/library/windows/apps/dn632424.aspx]
Your app might still get killed though - if it uses too many resources and other apps needs them, the app will get shut down by the system.

Related

How to restart a Desktop Bridge app programmatically

I have a Desktop Bridge app which needs to have a "Restart" button.
I've got it calling RequestRestartAsync method on the CoreApplication (described in this blog post) - but at runtime it fails with reason "NotInForeground".
I wonder if this is because of the way the Desktop Bridge technology wraps the WPF application. Any ideas on how I can cause the app to restart?
This is a new feature which is introduced from Windows 10 Fall Creators Update (v10.0.16299.0). Please note that not all UWP APIs are available for desktop bridge apps. You could check this document UWP APIs available to a packaged desktop app (Desktop Bridge). The CoreApplication relevant APIs have not been listed on the document. So, you cannot use this APIs in desktop bridge app now.
You can restart a Desktop Bridge app in the same way you can restart any regular Win32/WPF app. Nothing specific about it being on the "desktop bridge". For example you could spin up a new process, exit the app, and then have the new process launch a new instance of your app (and then kill itself).
I agree we should make the RequestRestartAsync() API work for Desktop Bridge apps as well to make this easier. We have logged a workitem on our backlog based on your UserVoice post.

Show desktop notification from one windows app (WPF) to another using webservice call

I have created WPF app and installed in two different PC. now I want that when I click one button from app in 1st PC, then I should get desktop notification in 2nd PC.
So I don't know how it will be done. Whether I have to use WCF or not or anything else? If I've installed this app in multiple PC then how should I send notification to particular?
I've tried to use signalR but I didn't understand how to invoke windows form method.
The application will not be closed. it'll just minimized in the tray. so my idea is that we can invoke App method from using WCF and show notification.
I want this kind of notification for my app but from webservice:
You can use self hosted WCF like here:
https://msdn.microsoft.com/en-us/library/ms731758(v=vs.110).aspx
Use net tcp binding, it will not require administrative rights.
Also there is a need to maintain a list of addresses/hosts of the PCs where your app runs. Then according to some logic you have there, choose the one that should show your notification.
You can also use a central app that coordinates, it may be a web app. Then signalR can be helpful. It becomes like a standard chat app... google can find you plenty of implementations for that.

Lightswitch Forms Authentication issues based on windows user?

First my apologies if I failed to find an answer searching - I tried a variety of search topics but none that were directly related.
I have a Lightswitch app deployed and working fine, running on IIS 7 and Windows Server 2008. It is an internal intranet app only.
I am using only FORMS AUTHENTICATION, all others are disabled.
The app works fine for MOST windows users.
However, some windows users get nothing but a blank screen - no login, no "loading..." and no silverlight "98%" display.
In the IIS log, I don't even see where it looks like it is being accessed when they attempt to load the app?
So, my question is, since this is FORMS authentication only, what could be causing it to NOT work based on which windows user is trying to run the app?
In other words, on the same Windows 7 machine, it works for 10 users, but not for others.
by the way, the application is remote - it is not running on the local machine.
The users ARE able to access the other ASP.NET applications hosted by the same IIS server in the same root inetpub folder.
The lightswitch application is using the ASP.NET v4.0 Classic app pool in calssic managed pipeline mode.
Any help greatly appreciated!!!
Happy to post any details/config/logs - I did not do so yet as I wasn't sure what would be most useful....
On the users machine you need to use Fiddler or the F12 tools in Internet Explorer to see exactly what calls are being made to the server and which ones are failing. LightSwitch is just an ASP.net website that launches a Silverlight application.
So the only other thing I can think of is that those users do not have Silverlight installed on their machines?
The users need to install the latest version of Silverlight. Apps built with LightSwitch 2011 require v4 or above and those built with LightSwitch for Visual Studio 2012 require v5
Silverlight Installation

Launch Silverlight out of the browser experience based on a url

So the user installs the Silverlight application to their desktop, could this desktop version be launched based on them visiting a url?
http://somesite.com/url?params
And the silverlight application could inspect the parameters of the url it was launched from?
No, only the user can initiate it becoming an out of browser application.
Not to mention that any application which does this without the user expecting it would probably be classed as a virus or at the very least spamming the machine. Not good for your reputation!

Silverlight 4 launch a trusted application into the browser?

I just lost 5 hours looking for a answer which i haven't been able to find :p
First, I'd like to force a trusted application (i need to access the file system) to display into the browser. Based on what i found on google a trusted application must be installed and launched as a desktop application (also called out-of-browser application).
So, i want to have an installed application on the client side but meanwhile, the user must also be able to start this same application into a browser window when he goes on my web site. Is this possible ?
Second, I'd like to give to the user the possibility to start the application from the browser. To be clear, the application is installed on the client computer but i want a button on my web site which starts the desktop application. How can i do that ?
Thanks
The answers are sort of and no.
Yes you can run an application that has been installed on the client also in the browser. However, not all of the installed application features will be available. Anything that requires elevated trust will not work inside the browser.
No you can't launch the installed application programmatically from within code running in the browser. The best you can do is display a polite message to the user to the effect that they have this app already installed and in order to access all of its feature they will need to launch it.
Yes, it is possbile since Silverlight 5, see my answer on silverlight-4-elevated-permission-inside-the-browser

Resources