Browser controls in Windows universal apps - wpf

Any one knows about it ?
Does the WebBrowser control in Windows Universal apps SDK is going to be the old WPF BrowserControl (the activex like control) that uses IE version < 8 only .
Or is any samples to explore the features of universal app Browsercontrol anywhere?

Check out WebView control
The msdn page mentions that
WebView always uses Internet Explorer 11 in document mode.
The sample can be found here

Over the past several months, we have made numerous improvements to the Microsoft Edge rendering engine (Microsoft EdgeHTML), focusing on interoperability with modern browsers and compliance with new and emerging standards. In addition to powering Microsoft Edge, EdgeHTML is also available for all Universal Windows Platform (UWP) apps via the WebView control.
Ref: https://channel9.msdn.com/coding4fun/blog/Building-your-own-Windows-10-Web-Browser

Related

Is Web Browser control in WPF perfect enough to support modern browser features?

We did some experiments loading sample HTML pages in to the latest version of WPF Web browser control which comes with VS 2017 IDE. Seems perfect in most of the cases except when loading following URLs which throws error messages, which is not the case in modern web browsers like IE, Chrome.
E.g.
1. Error message for W3Schools:
Error message for HTML5Rocks :
Please let us know whether WPF browser control is perfect enough to render/support modern web technology features in our desktop application projects?
-Thank you
I believe the "modern" browser experience on Windows in Microsoft Edge. You could use the WebView control to use it in your WPF application as explained in this blog post. This assumes you are targeting the April 2018 release of Windows 10 or later.
If your users are still in Windows 7, you may want to look for a third-party browser control such as for example CefSharp.

Is there any way to port WPF application to Windows IoT?

We have developed a WPF application runs great on Windows 10. At this point we are looking for ways to run this software on a Minnowboard. This board has a Windows IoT OS. As I've seen it is only capable to run UWP applications. Is there any way to make our app run under IoT? Thanks.
Of course you can port your code. Depending on how complex your app is, it still might need some rewriting as many APIs are not available anymore, have changed or were added.
Maybe these links help you:
Move from WPF and Microsoft Silverlight to WinRT on MSDN
UWP Bridge tool by Mobilize.NET
UWP samples by Microsoft on Github
Windows 10 IoT Enterprise version enables WPF apps

how to port existing wpf desktop apps to Windows 10 universal apps

So I have an existing windows desktop application which is written using WPF. I searched through the net for possible ways of upgrading it to Windows 10 universal app but cant seem to find anything on this upgrade path. There are documentation available to port WPF desktop app to WinRT (which according to my understanding is no same as Universal platform) but nothing on this topic.
This link https://msdn.microsoft.com/en-us/library/windows/apps/dn751495.aspx
shows up options to "Port your app to the Universal Windows Platform (UWP)" but doesn't mention anything for this upgrade path.
So I am curious if this is even possible? If yes, are there any documentation or examples to follow? If no, why?
Thanks in advance!
You cannot upgrade a WPF app to a Windows 10 Universal app, because those are very different platforms.
Both have capabilities and markups that doesn't exist or have an equivalent in the other.
So there is no "simple" upgrade path, you would have to rewrite a lot of UI but you can maybe reuse the "business" part if it's written in a Portable Class Library.

Is Silverlight recommended for new development?

At my job we are developing a GIS application which will be developed using Silverlight + .NET
But, I heard that Silverlight will not be supported by Microsoft as also they are stopping Silverlight, is it true ?
Is it suggestable to use Silverlight if so with which version of silverlight we can use. ?
Thanks.,
Use Silverlight 5. Current version have 10 year support, and it better than Flash, java or damn it html.
In the future you can migrate to another .NET-based framework by easily porting code.
About silver light support, you can find these answers from Microsoft Silverlight Support Lifecycle Policy.
Keeping in mind that MS would support these browsers till 2021, I would recommend using Silverlight5 if you really have to use Silverlight.
However for new developments I would recommend you to evaluate Html5 as well.
YES! Silverlight is still the best technology to use for web based Line of Business applications. Silverlight will be supported for another 10 years and it will be available within Windows 8 desktop. Silverlight +[Arc]GIS are a great combination. It is so easy to create full functioning application and with little effort. Silverlight is not dead. It is still a great technology to use that is available on (almost) every platform.
Ultimately it comes down to:
1) What do you know: Are you an HTML/JavaScript ninja? Then use that, do you know Flex better then your own children? Or are you a skilled .Net assassin?
2) How much time do you have? Do you want to learn something new and have gobs of time? Then go for that new shiny object (HTML5) and get yourself some street cred.
This probably belongs on programmers.stackexchange.com. However:
Silverlight will continue to be supported for some time, but all signs point to it no longer being actively developed.
If you want a technology that's actively developed, I'd recommend HTML 5 for web based applications and WinRT for Windows 8+ native applications.
Ultimately, though, you should go with what works best for your situation. After all, WinForms is still used on many successful greenfield projects.
Silverlight is based on the NPAPI architecture that is no longer supported on Google Chrome (from browser version 42 upward) though you can still run it on IE and Firefox. HTML5 is supported on all browsers.
From a career standpoint, using Silverlight (which uses XAML) gets you an easier entry into developing apps for Metro/Windows Store/Universal Windows Apps (these can be developed using HTML5/JS too but you'll find a larger developer base using C#/XAML).
Finally if you're already a WPF developer, it's fastest if you develop for Silverlight. See Silverlight vs Flash vs HTML5.

Silverlight widgets cross-plateform?

Can I use Silverlight to build cross-platform desktop widgets?
Silverlight Vs WPF
First of all, WPF is not exactly Silverlight. They essentially require different run times. Silverlight Runtime is a subset of .NET, and needs to be installed by the client, to view your SL applications over a browser. Presently SL runtime is available for Windows and Mac. Moonlight is still not full fledged, and is evolving, for Linux.
WPF, on the other hand, is purely on top of .NET runtime, and is available only for Windows.
You can use XAML to develop user experiences in Silverlight and WPF, and as long as you stick to the Silverlight subset, you can compile your XAML in WPF as well.
Desktop Widgets
Now, your thought about building cross platform 'desktop' widgets - Do you want to host a Silverlight application in a desktop window? Silverlight 3.0 provides support for hosting silverlight controls out of the browser.
Otherwise, see my blog entry on hosting Silverlight using a browser shell. http://amazedsaint.blogspot.com/2008/12/thinking-outside-silverlight-sandbox.html.
This post is revolved around
Hosting the HTML Page with Silverlight
in a Winforms/Webkit desktop application
using a web browser control, and
communicate to and fro using HTML
DOM
Embedding a light weight web server
with in the Host application, and
handle requests to perform such
operations
But remember - it is not WPF. Hope this clarifies.
In Silverlight 2.0, you won't have any such luck.
In Silverlight 3.0 (currently in beta), however, support has been added for Out of Browser Capabilities, which means you can download and run Silverlight apps from your desktop.
The Silverlight platform in general is cross-platform, so external (desktop) aplications in Silverlight 3.0 will be exactly the same.
Quoted from the What’s New in Silverlight 3 Beta? section of the release page:
Out of Browser Capabilities. The new out of browser experience in
Silverlight 3 enables users to place
their favorite Silverlight
applications directly onto their PC
and Mac, with links on the desktop and
start menu—all without the need to
download an additional runtime or
browser plug-in. Further, the new
experience enables Silverlight
applications to work whether the
computer is connected to the Internet
or not—a radical improvement to the
traditional Web experience. Features
include:
Life outside the browser. Silverlight applications can now be
installed to and run from the desktop
as lightweight web companions. Thus,
users can take their favorite Web
applications with them, regardless of
whether they are connected to the
Internet or not.
Desktop shortcuts and start menu support. Silverlight applications can
be stored on any PC or Mac computer’s
desktop with links in the start menu
and applications folder, and so are
available with one-click access.
Safe and secure. Leveraging the security features of the .NET
Framework, Silverlight applications
run inside a secure sandbox with
persistent isolated storage. These
applications have most of the same
security restrictions as traditional
web apps and so can be trusted without
security warnings or prompts,
minimizing user interruptions.
Smooth installation. Because Silverlight applications are stored in
a local cache and do not require extra
privileges to run, the installation
process is quick and efficient.
Auto-update. Upon launch, Silverlight applications can check for
new versions on the server, and
automatically update if one is found.
Internet connectivity detection. Silverlight applications can now
detect whether they have Internet
connectivity and can react
intelligently including caching a
users’ data until their connection is
restored.

Resources