C#: Self Hosting Web UI or WPF?

I continue to bounce back and forth between self-hosted web UI and WPF UI for implementing simple user interactions.

WPF is likely to be easier to build the right sort of thing with but is a bit less flexible and more ‘backward looking’. Web interfaces require a self-hosting solution if they’re going to be stand-alone and cross more lines of language and environment.

On balance the web UI path is better as a learning experience and aside from a few corner-cases (OpenGL say) likely to  result in a better user experience in the long run.

I’m still looking for the right self-hosting solution and UI framework solution. I’m going to have to settle on one shortly so that I can being experimenting in the ninecrows sandbox and getting a feel for the technology.

Current links of interest on the self-hosting front:

There also seem to be some hard choices between versions of the framework…classic and core in particular.

More to learn as things move forward. I expect I’ll wind up doing things with both/all before I’m done as they have different strengths. The sorts of things a WPF/WinForms/MFC UI can do in terms of digging into the system and being screen real-estate aware along make them of great interest.

C++/CLI

Recently bought a couple of used books on C++/CLI to read. This looks like the most seamless and high performance approach to .NET/Native interop.

and

Both a little old (though there isn’t much newer really). I’m a bit concerned that Microsoft might move away from supporting this language as it must  be a bit involved to keep up as new releases happen. I’m going to look at adding some interop samples using this technology to my github in the near future.

Wix installer added to C9ServiceManager project

I’ve now finished the wix installer and tested the result for C9ServiceManager. All looks good with install and uninstall.

There’s still work to be done on the code that executes inside the service and some of the configuration reading from the registry. Hoping to get to that tonight.

I’m adding an interop samples project to github to hold working samples of some of the things I’m playing with on the C# to native interop front. There are too many APIs that aren’t exposed to .NET but contain important functionality. I’m currently investigating options on that front and coding up some sample approaches.

I expect this project to be a ‘living’ repository of code pieces in that area for some time to come.

Did a Little More Research on Interop During Lunch

I did a bit more research on interop topics during lunch today. I’m going to try to write up some samples using interop to work with the file information and volume information APIs that aren’t available in C# tonight.

If all goes well, I should have something to push up to github as a set of code samples. I don’t expect this to be a finished product, but should be interesting in any case.

I also want to fix the Wix issues with my service sample and get that pushed with a working installer. Probably won’t get the guts finished but should be able to install and uninstall the thing without dev tools.

Once Again a Linux Box

I have a history of bringing up a home Linux machine and then finding a need for that hardware doing something windows-y in short order.

I’ve just added a new SSD to one of my NUC machines and installed Ubuntu 17 on it. I’m expecting that I’ll likely move this to a new NUC at some point in the future as I do have windows work for the current NUC (but can live without it for now).

I’m looking at doing some microservices and MongoDB work in the sandbox in the near future and I’d like to have a working (non-VM) Linux install to host some code and as a built platform for Linux preferring tools. Worst case I wind up switching the SSDs back and forth as my needs vary.

For now I’ll need to get this install configured when I have time and look at putting MongoDB on it at a minimum. I’ll probably add Node and few other bits (assuming they don’t just come out of the box these days) to make this machine broadly useful.

Looking at C++/CLI Again and Other Things

Looking forward at sandbox projects I want to work on I find that there are many missing things in the C# world that can only be accessed from native code. The support in PInvoke and COM interop is undewhelming and C++/CLI seems to promise a relatively seamless interaction between the two worlds. I’ve just ordered a newer book on the technology and expect to read through it when it arrives.

I’ve added an installer to my current sandbox project (a service that manages the state of other services based on time of day). I’m having some issues with my local Wix install and won’t be pushing the update to github until I can successfully build the installer.

Over to C# Interop and Some Native Code

It has been a little while since I’ve gone diving into Win32. I’m looking in there a bit now though. I’ve been using mklink on the command line to create NTFS symbolic links for various purposes. Once those show up (and volume mounts), file management tools suddenly need real confidence that they’re looking at real duplicate files and not multiple links into the same file.

This quickly leads into areas of the Win32 API that haven’t been directly exposed in C#. The

GetFileInformationByHandleEx() with FILE_ID_INFO

API exposes the required information. There are other bits of information in the GetFileInfo* APIs that may also be important. I’m looking at Interop again as a way to gateway this sort of information across.

I’m not all that happy with PInvoke as it narrows everything down to a C style interface. The COM interop mechanisms are clunky and tied to coclass rather than interfaces in ways that seem to subvert the basic design tenets of COM. C++/CLI is close to the sort of connection I’d like, but is complex and I question whether it will remain stable in the long term as it is a bit of a fringe technology.

At this point I’m refreshing my memory and considering. I’d very much like to build a capable and safe tool for managing (and cleaning up) duplicate data. File uniqueness is going to be one of the key features here…

Bouncing around…MongoDB, Angular and C#

Bouncing around a bit this weekend…doing a more detailed read-through of the book I’ve got on Angular  as this seems like one of the better ways to create modern user interfaces, digging though my MongoDB stuff  a recent acquisition and looking to wrap up the sample service I’ve been working on. Add in finishing up my resume update (I try to keep my credential up to date and use layoffs at work as a reminder…had one this summer so  it is about time) and I’ve got a pretty full weekend.

Lots to learn as I come up to speed on the web side of things in a more serious way than I have in the past. I’ll continue sharing any interesting sandbox projects on github.

Looking at pfSense as a Firewall

I’ve got a small, multiple-ethernet port computer arriving from Amazon today (a QOTOM Core i5).

I’ve been running SOHO boundary routers for the last many years and finding that they’re somewhat inflexible, eventually stop being updated and often frustrating in the features that they omit.

I’ve had a new boundary router sitting on the shelf for about a year that I still can’t get my ISP connection to provide an address to. It works fine as an upstream off of my internal network though. There isn’t enough diagnostic information readily available to figure out what is happening and shutting my external connection down for extended experiment breaks isn’t really a happy thing either.

I’m expecting to install pfSense on the machine when I get it. I’ll have to come up to speed on the configuration for pfSense, but I expect that once I’ve got it in place, the project will continue providing updates over a much longer span than other options. I’m also hoping that inbound VPN capability can be set up without extra cost client packages and other entanglements…

I’ll update once I’ve got the hardware in hand and have started in on the setup process.

Nice to find that there’s a C# port of iText open source

Looking around at PDF processing code out there. iText kept showing up but it is a Java library and these days I’m focusing on .NET (at least for a while). Found that there is a C# iText on github. Not sure when I’ll get around to messing with it, but being able to work with PDF these days is a very useful capability (and I’m not doing anything closed source in the sandbox anyway)…

Engineering execution and creativity mixed for the best results…