Is it possible to access functions within a WPF applications using HTML5? - c#

I am still a noob so i really need help please.Is it possible to access functions within a WPF applications using HTML5?
So Basically i have a WPF application running on the same server and it has a print function. I want to add a html layer to this so the function can be executed via the html layer.

HTML5 Websockets And Canvas
With Websockets in HTML5, we are going beyond the unidirectional, stateless http to a full duplex, high speed connection infrastructure between the server and the client. - See more at: http://www.amazedsaint.com/2011/04/wpf-over-web-sockets-how-to-pump-wpf.html#sthash.vNEk0h8M.dpuf

I think i have found some sort of solution to my predicament,
Have a look at this site
HTML5 Websockets And Canvas is what he use and give a good explanation. Hope you guys find it useful

Related

ASP.NET C# Webcam Integration

I'm curious, how do you integrate a webcam with an ASP.NET C# application in a 'live broadcast' type scenario? I have no idea where to start with this but really interested to learn how it works in terms of detection and live streaming. A point in the right direction would be great, thanks.
Nothing to do with ASP.NET MVC really. The camera's on the client, so you need to use client scripting such as Flash or Silverlight to access it. Here's for example a jquery plugin (based on Flash) which allows you to control the camera (once the client authorizes the site to do so).
HTML5 might also be an option one day.

Is it possible to embed Windows Sidebar Widgeds in own .Net Application

I'm trying to embed Windows-Sidebar-Widgets into my own .Net Application (WPF and C#), but I dont't realy know where to start. I googled a bit but only found SDK and tutorials for widget-development. I found that there is a small service in Windows, running the widgets. My thought was that I could perhaps fake this service and provide his functions whithin my programm, so that I can run and show the widgets.
Does anyone have some tips on how to do this? Or some experience in doing so? Perhaps there is even some kind of libary for that kind of stuff?
If this is not possible it is also an option to switch to an OpenSource widged-manager to use this widgeds, but this is only an emergency solution and the windows-gadgeds would be very appreciated.
Some information about my system:
I've written some kind of small windowmanager for childwindows in my application. And on the top of this I want to show the widgets in some kind of HostWindow.
Any hint will be appreciated.
P.S.: I would be willing to share the results if I (or we) get this working :-)
I've never seen a library for hosting gadgets, but since they are basically just websites you could use the MSHTML component to host any arbitrary gadget in theory.
This isn't to say it will be easy.
You'll need to extract a gadget to some temporary directory, spin up something hosting MSHTML (in WinForms WebBrowser would be convenient), navigate to the appropriate file in that temp directory (discovered by parsing gadget.xml), and shove something resembling the System object into the gadget.
As a starting point, inject some script that sets System = window.external; onload and WebBrowerser.ObjectForScripting = new FakeGadgetSystem().
FakeGadgetSystem will need [ComVisible(true)] and to implement a decent amount of stuff. I'd advise grabbing a widget or two to test with that mildly exercise the Gadget API, and then slowly implement the calls they make. It'll be a long haul for 100% compatibility with the official gadget hosting service.

How to develop website for mobiles using asp.net(C#)

Is there any tool available for developing mobile websites using asp.net (C#)...
or else any other tool???
The same tools as you develop any other websites in C#: typically, Visual Studio. A mobile website only differs in presentation and in some capabilities (eg: javascript/css may be limited), but functionally it's the same as a "non-mobile" site.
There's no fundamental difference between regular cross-browser development and mobile development. You're still writing the same code, the same markup, etc. You probably need to be more aware of the limitations of the browser than usual, but that doesn't change the tooling or process.
Is there a particular problem you're having that you can't solve?
If you are going to develop a website for mobiles (as opposed to a native app), then the server side language does not matter that much. It's more a matter of the css and client-side framework (if any) you are using.
One option would be to use asp.net mvc on the server side and jQuery Mobile or http://jQtouch.com for the client side. There are also other options, but these are the best I have found for my own use.
As other people have said, if it's a website you're developing then the tools are the same as any non-mobile website.
Another option for the client side is Sencha Touch.
Take a look at Mobile Device Browser File (http://mdbf.codeplex.com/). Actually that particular project is no longer supported, but it used to work quite well. It basically automates a lot of the leg work of identifying the mobile client and rendering the right styles and script. You may be able to find something similar with a bit of searching.

How To Create Cross Browser Asp.net Custom Control

I'm goingto create an asp.net control which should be cross browser. and support some skin - multilanguage and rtl & ltr support.
I want to know what should I consider and also looking for a good article
Write valid xhtml.
Read this article on How to make Cross Browser Websites. It doesn't really have to do with if you use asp.net or php to create re-usable web-controls / sites. You just need to follow the standards and maybe apply some hacks if you want to support older versions of web-browsers.
Have a look at this series: Building ASP.NET User and Server Controls
Cross browser designs generally depends on what kinda design features you want to support, best thing to get started with is learning asp.net control adapters, It's basically bunch of ready made samples that shows how to detect browser early in the execution of the request and reflect to the design using in-built actions provided by asp.net technology, or write your own!
Hope this helps

Good framework for a C# developer to use for visually stunning presentation layer

I am about to write a front end app, which will be used as a media center app. It will plug directly into a high definition TV. Essentially transforming my laptop into a media player. While this concept is not new, I want custom functionality, so this is why I am not reusing existing products.
I'm a C# developer, so the app should ideally be written in C#. And there is 1 other consideration, I need to accept input via the MCE Remote.
I was considering using Silverlight for this. Would you recommend this? Or any other recommendations for frameworks before I begin planning around this.
Thanks in advance.
This is the type of stuff that the Windows Presentation Foundation was meant for. You'll get a lot more access to the hardware than Silverlight would provide (I.E. that MCE remote you mentioned). You mark up your UI with vector graphics/XAML, and then perform the logic with C#.
EDIT: WPF also has support out of the box for animations which can make your UI a lot more interactive.
EDIT 2: Scott Hanselman has written a really cool application called BabySmash and posted the source online. It basically intercepts keyboard input and shows shapes and sounds on the computer. It's a good "child-proofing" method for your PC. The code could provide you with some insight into WPF and how to do the animations and interactivity that you're looking for.
Is this a desktop app? If so I would use WPF. Silverlight is a subset of WPF, so using WPF you could potentially do more.
Silverlight or WPF, if you want some extra power. Both have a similar programming model (with XAML and code-behind) so you might be able to start with Silverlight and move up to WPF if you need.
The VLC api might be useful for playing your media, someone has created a C# wrapper for it:
http://wiki.videolan.org/.Net_Interface_to_VLC
WPF is certainly the way to go, and for playing media check out the excellent WPF MediaKit: http://wpfmediakit.codeplex.com/ I've used it successfully in many projects.

Categories

Resources