An embedded application for windows desktop using .NET platform? - c#

I'm rebuilding an Embedded application:
Prebuild application Specifications:
Use : For dispaying the captured images/video from microscope image capturing device on windows based PC or Laptops.
Sepcifications: Prebuild on .NET plateform using VC++
Flaws : Lacks some specified features.
Current Requirement:
Want to rebuild that entire application using C# and add some additional client features.
My Questions:
Is it feasible to develop such application in C#.net?
If yeh,What kind of resources available in C# to develop desktop embedded application?
Any references which show any of such kind of application?
Your suggestions on building this kind of application.
P.S. It is essential to buid it on .NET platform.

I think by "Prebuild" you mean "Existing". Why do you want to rewrite the complete application? As you have stated that the application is written in C++.Net. You can easily add all the new functions in C# and use that code from your existing C++.Net code.

Note: I'm making this answer CW because the question is hard on the limit towards some close reasons. Everyone feel free to edit and extend it.
Is it feasible to develop such application in C#.net?
That's a tough one...from the top of my head I'd argue that it doesn't matter. If you know C#, then build it in C#, if the client wants it in C#, then build it in C#. You'll most likely have to use COM-Components or API-Invokes anyway to accomplish this.
If it is a TWAIN device, you might be better of to stick with VC++, I found TWAIN on .NET a real pain in the a** and have given up on such features. Same goes for WIA, but that might just be me.
If yes, what kind of resources available in C# to develop desktop embedded application?
I guess you mean a Widget? In that case I have no idea, I never really looked at that (at least not on Windows). But as far as I know widgets on Windows consist of a data-backend and a HTML/JavaScript-Frontend, so you'll most likely have to develop the two separately.
Any references which show any of such kind of application?
I guess any WIA/TWAIN application would be a reference, at least your description sounds so.
Your suggestions on building this kind of application.
See your first question.

Related

Windows Embedded wpf application

I have build a WPF media player application in c# .Net 4.0. I would like to take this WPF application and put it on a Windows Embedded operating system. This would take out all the things I don't need and just make a simple power on and my application loads. I know there will be a lot of work in order to make this happen and I'm just wondering if someone can point me to a good starting location. I've looked around a lot but haven't found a good tutorial on how to go about doing this or what version of windows embedded I would need etc. Any help would be greatly appreciated.
Thanks!
if you are using Windows Embedded 8, it's basically full windows with lockdown features, thus any application that can run on normal windows will be able to run on it

Windows 8 DirectX SwapChainBackgroundPanel Questions

I come from two distinct backgrounds: I have much experience with WPF/XAML/C# app development and equal experience with C++/DirectX development. I hear about the ability to use DirectX and XAML together and I get all excited, but now I have hit this wall.
I'm trying to use the SwapChainBackgroundPanel in a WPF application. But I'm trying to use C# as the underlying language. I keep running into issues where, regardless of the type of C# project I create (PCL, WPF, Windows Store) none of these types are defined [namely I've been looking for SwapChainBackgroundPanel and some other DX stuff like the device and etc.)
So my question is: how does this work in C#? I've seen the simple shooter example from the MSDN done in C++ and it makes sense; I get it. But I feel like I'm missing one of those "gotcha's" when trying to do it in C#.
Any advice, or maybe a link to an example, or at best a little tutorial on setting up a C#/XAML/DX app would be amazing. Thanks everyone.
There is no SwapChainBackgroundPanel available to a WPF app (that is in PresentationCore). The closest you are going to get is the D3DImage class, but it's not exactly the same. See this discussion.
I don't think you can fully utilize the DirectX capabilities of a Windows 8 Store app (SwapChainBackgroundPanel) from C#. You're going to have to do your DirectX work in C++ as in the example you described. You can certainly combine the three (Xaml, C#, C++) as in this example, but I don't think a 100% C# app is possible.
The answer is wrong. It is possible to fully utilize C# throught a wrapper.
I did this myself with SharpDx which is actually one of the microsoft recommendations to use DirectX in C#.
As for the choice of XAML Library, Universal Windows App 10 or Windows Store App 8 is the way to go. Use a SwapChainPanel instead of SwapChainBackgroundPanel.

Develop a C# application for Windows Mobile, Android & iPhone

I have a project where I need to build a C# application that is able to run in iPhone, Android and Windows Mobile.
For windows Mobile that is no problem, but I think its a challenge when we try to develop for Android and iPhone.
I've been searching for solutions and i found some information about Mono-Android and MonoTouch.
My question is, has anyone used this API's? Are they good?
Do they really take advantage of Android/iPhone native api's?
Can I with only one source code create an application for both platforms?
And finally, is there any other way of creating a C# application for these mobile platforms?
Yes they are very solid. They give you .NET 4.0 with all of that capability & the ability to share data access, networking/API integration, and business logic in shared assemblies. You'll of course have to write the user interface portion of the applications in C# but specific to the platform.
For example, MonoTouch is like Cocoa in C#. It will feel unlike your typical .NET programming style, so make sure you get comfortable reading Objective-C for documentation & assistance.
Also recommended is to follow the UI guidelines of the platform in question. Don't create a cookie cutter app for all platforms or it will suck everywhere.

How to write applications for different platforms? Linux, Mac, Windows and Mobile Platforms

We want to write a client for an online service which should be available on as many platforms as possible. This question is about what programming language and framework we should use to create this client.
These platforms are required: Linux, Mac, Windows, iOS (iPhone, iPod, iPad) and Android. The more the better.
For the mobile platforms there is Titanium Mobile. I haven't tried this thing yet, the website says you can develop for both iOS and Android using web skills such as Javascript. I don't know yet if you can deploy for both platforms using the SAME code. It would be great!
There is also Titanium Desktop but I don't like the idea that the complete source code is shared with the final application. Titanium does this for Mobile too but it isn't that easy to modify an app loaded via App Store.
So, what other way is there to create an application which runs on at least the three major desktop platforms? I thought c# with mono would be the way to go but I just realized that you need to use mono with MonoMac in order to publish it on the Mac App Store and use things like Growl. And since MonoMac is naturally only available for Macs, it's again not possible to deploy the mono app on all platforms without rewriting it for at least the Mac. And it would be nice if the app looks "native" on all platforms. Gtk# just does not look good on a Mac. It's "okay" on Windows and great on Linux.
I know we could use Objective-C for iOS and Mac, Java for Android, C#.net for Windows and C#.mono for Linux but the main point is that we don't want to write the same app in a lot of different languages. That would make development and maintenance really hard.
And we prefer languages with C-style syntax which are much easier to learn for us PHP web developers. Btw: We dislike Air and I'm not sure about Java since I never used it but it also does not look "native" and it feels kinda slow.
Edit:
Just a note: It wouldn't be a problem to create an own form for each platform if at least the remaining code is the same. Is it possible to use MonoMac, Gtk# and Win Forums in the same C# application? And I'd prefer C# over C++ as I have no skills in C++, so I first need to check how hard it is to write with Qt.
Another note: We don't plan to spend much money and because we need to pay Apples Developer Programs we want to use free or cheap technology. Preferable Open Source.
Just use C# for all of the above.
The mono project will cover Mac and Linux, with monodroid your android requirements are covered and monotouch will take care of iPod/iPad/iPhone.
In regards to UI - mono has full support for the System.Windows.Forms namespace, so you don't have to use GTK# if you don't want to.
I don't think I need to mention windows support ;)
If you really want to support all those platforms from a single application, your best bet will be to create a web application. With HTML5, such an application can even be cached on the device and used when no connection is available. Also, that strategy would make it feasible to customize the UI based on the device running the app.
You will not have good luck if you set out to build a single native app that runs on Android and iOS, let alone all the other platforms you mentioned. The reason that they're different platforms rather than the same is that they're, well, different. They have different capabilities, run on different hardware, are built with different languages, employ different application models with different user interfaces, and have audiences with different expectations.
The best solution I've come across over the years is Qt SDK.
Great support for all major platforms, Symbian, OS X, Linux flavors, Windows, Windows CE (mobile), Android and iOS partial support and etc.
Its base is C++ but bindings for almost every language (like C#) is available. Lots of help and support is also covered.
The core Qt libs are very fast and extensive, And the whole KDE desktop (of Linux) is done with it. Famous software like VLC and VirtualBox are done in Qt.
Another relatively new way of doing cross-platform development is to use the open source Eto.Forms, which allows you to have one UI codebase target each platform's native toolkit. It is a UI abstraction layer that can target GTK#, MonoMac/OSX, WinForms, and WPF.
There is also an iOS port in the works.
Java sounds like the best fit. It is cross-platform, easy to understand, has a huge userbase and android is based on it.
Depending if you need an offline interaction mode, it sounds like you should develop a web application. You can develop a mobile version and a desktop version and thus support all the of the above platforms. Look at youtube's application for Iphone, it retains the same functionality as the the iphone app but is purely html. Furthermore, html5 capable browsers could also have the ability to run offline.
Crazy as it sounds, check out Flash/Flex - it is cross platform, code once, run everywhere ,now compiles down to native code on e.g. Android and iOS and the 10.1 player is shipping all over. I had to solve exactly this problem and when Flash Builder Burrito catered for mobile after working with it for a while I have switching from C#/Flash hybrid to Flash only for clients. (Our backend is C#/Node/C++, etc).
Depending on your timelines and needs it is something look into.
Some random links to peruse:
Blog post about performance and video to single app multi device
Developing flash and flex applications

How to read installer shortcuts with C# (WPF)

Background: I've decided to teach myself C# through WPF, and I'm writing a small application that needs to get a list of Start Menu shortcuts and their targets and store them. Basically, I'm trying to take all the shortcuts and put their target applications' paths into memory. However, I've run into a problem trying to read Windows Installer shortcuts (the ones that point to something like C:\Windows\Installer\{90120000-0030-0000-0000-0000000FF1CE}\wordicon.exe -- Microsoft Office is a good example of this). I did some research and it seems that Windows uses some behind-the-scenes magic involving the Registry to find the actual location of the file.
Question: How can I get the actual target of these Windows Installer shortcuts in C#? A lot of sources I've found point me to the IShellLink interface, but I don't know how to use it with C#. I'd prefer to use Windows API calls (or, even better, a .NET library) instead of manually looking through the Registry, but I'll take any guidance on the issue.
After doing more research, I found an easy answer here. It's basically using a combination of the MsiGetShortcutTarget and MsiGetComponentPath functions of msi.dll.
I'm afraid IShellLink IS the Windows API for using shell links! The Shell API is heavily COM-based.
But the good news is that COM interop works very well in .NET. This site is usually a very good resource:
http://www.pinvoke.net/default.aspx/Interfaces/IShellLinkA.html

Categories

Resources