PDF Lite Viewer

I have decided to release the PDF Lite Viewer app that I built initially for my own personal use, but others may find it useful.

Its a keyboard driven PDF viewer that allows me to read PDF Books on my GPD Pocket 2 computer, rotated, like a book, and using the arrow keys to page through it.

Trying to emulate the traditional eBook experience, but as none of the eReaders seem to have decent PDF support, I thought I would see if this works. Check out the video below, and you can download it from its own page.

It can be downloaded here.

How it was built

This application is actually built using the Windows Presentation Framework for the main application in C#, however, it actually uses the Windows 10 API’s to work with the PDF files as it has suitable methods built in. It reads the PDF, and renders each page to a bitmap and is then displayed on screen.

Standard Keyboard events are used to trap the keys.

The main window itself is simply a canvas to which the bitmap versions of the PDF files are displayed.

Its a fairly simply application, but I am pleased with the result.

DevOps Home Server – Part two – Software

For the purposes of my own home DevOps server, I decided to use the range of Atlassian software.

Source Code Control Atlassian Bitbucket
Project and Issues tracking Atlassian JIRA
Documentation Atlassian Confluence
Build and Deploy server Atlassian Bamboo
Code Analysis SonarQube

The main reasons for this are :

  • I have used these applications in a previous job
  • They all integrate really nicely with each other
  • They are affordable (even though there are free open source equivalents)

Once they are all set up, and connected together, you can quickly change between them when browsing the web interfaces.

In terms of price, each one of these applications (apart from SonarQube which is free) costs $10 for a permanent license for 10 users.  If you wish to get software maintenance, then you can pay that price every year (actually, its half that for extending the maintenance after the initial purchase), but in my case, the initial purchase is going to be fine, costing not much more than a decent takeaway.

Continue reading “DevOps Home Server – Part two – Software”

Portals Support added to CRM Utilities for Visual Studio

Get it on the Marketplace

I have updated my extension to support publishing of files from Visual Studio to Microsoft Dynamics Portals.

The tool now supports publishing files to Web Templates and Web Files, allowing you to use Visual Studio to edit and track changes of your portal related files, and quickly update Dynamics with the appropriate Portal files.

Web Files and Web Templates are simply listed within the Web Resource linker dialog for you to select.  You can then publish the appropriate files within your Visual Studio solution to Dynamics.

If you have installed the extension from the Marketplace, then it should prompt you to update, but if not, you can get it from the below link.

CRM Utilities for Visual Studio

My utilities are now on the Visual Studio Marketplace

Just a quick update to say that all of my Visual Studio extensions are now on the Microsoft Visual Studio Marketplace, and are available to download and install direct from Visual Studio.

Visual Studio Marketplace

Simply go into the Tools menu and choose Extensions and Updates, select Online and search for me, James Hall.  My extensions are the top two in the list.

In theory, if you install them this way, you should get notified of when I update them.

CRM Utilities for Visual Studio – Update to menus, and class generation options

Today I have released an update to the CRM Utilities for Visual Studio 2017 extension.

New features:

Reorganised the menu structure so that the Generate Class options are now grouped together.

Generate Class options menu to allow a custom namespace and class name to be used when generating the class files to represent the Dynamics Entities.

Redesigned the Connection dialog to make it look better, and to include a hyperlink to the instruction pages on this blog.

 

Download
Please note this feature is only available in the Visual Studio 2017 version. This version may still install on VS2015, although I have not personally tested it.

CRM Utilities for Visual Studio – Publish All option

A recent request for a new feature has resulted in a quick update to my CRM Utilities for Visual Studio.

There is now a Publish All Web Resources feature which will publish all files that have already been linked within a Project.

Hopefully this will be very useful for making sure all the Web Resources part of a solution are up to date in CRM before doing a Solution release.

Get it from here

CRM Utilities for Visual Studio – Generating Entity Classes

Most CRM Developers either use, or have at least heard of CrmSvcUtil for generating early bound classes for developing code and using the resulting classes to manipulate CRM data.  I personally do not like working with early bound entities as the resulting class files are huge, and I personally prefer working with the standard Entity Framework for creating and updating entities, and for Linq queries.

Often, I use some helper class libraries that I can use to represent the custom entity names and attributes, so that they can be referenced in code and provide a degree of separation from the actual Schema names and to make code easier to write, and support Intelli-sense.

Something like the code sample below:


public static class Contact
{
    public static const string EntityName = "contact";
    public static const string Name = "fullname";
}

This would then allow you to do the following:

public void createContact()
{
    Entity contact = new Entity(Contact.EntityName);
    contact[Contact.Name] = "Joe Blogs";
    service.Create(contact);
}

I was offered a suggestion by a fellow developer that wouldn’t it be good if my CRM Utilities for Visual Studio allowed you to generate this kind of Class file automatically.  Well, I thought it was a brilliant idea, and so thanks to the wonderful gentleman  of XRTSoft, here it is.

Its split into two options, one to generate classes for your Custom Entities, and one to do the Standard CRM entities.

The resulting file will look something like this:

Notice that for each Entity, it will add the Logical Name, Primary ID Attribute, and the Primary Name Attribute as standard, and then all of the attributes as well.  It will also add sub classes for any Option Sets to allow you to reference specific Option Set Values without having to look them up in CRM.

 

Download
Please note this feature is only available in the Visual Studio 2017 version. This version may still install on VS2015, although I have not personally tested it.

 

GPD Pocket review

I’ve always enjoyed small gadgets. They make me happy. I always seem to have a desire to game and compute on the go, using all manor of devices. I remember when I was a young lad, and I was holding down a Saturday job in a computer shop, selling Amigas, PC’s and games etc. I remember at one point; my boss had a Psion Series 3 sat on a shelf that he was given by a rep as a freebie. He had no intention of selling it or using it himself, and when I showed an interest in it, he took advantage of me. I don’t remember how much he charged me for it, but it wasn’t cheap. Since then I was hooked, moving on up to the Psion Series 5, the Psion Series 7, and countless PDA’s in the years after.

Now, everything is a lot more advanced, but, not as fulfilling as it once was. While waiting for the Gemini PDA to be released (a re-invention of the Psion Series 5, with a full keyboard, but Android, and smartphone like internals), I wanted something that would let me compute on the go, and that’s where the GPD Pocket comes in.

It’s a small 7″ Windows 10 PC, with a keyboard, but in this modern age, runs an Intel Atom based processor and has 8GB RAM to hopefully give it the ability to perform at a decent pace. 128gb of storage is not as much as I would have liked, but it is sufficient enough to be more than useable.

Build quality

The build quality of this device is impressive. It’s a full metal body, no flex, feels cool to the touch and looks like a little mac book. When opening it, the screen can be positioned at any angle you choose, the hinge is solid, and when switching it on, looks amazing. The screen is very bright, the resolution is spot on (it’s a full 1080p display) and is very readable. The keyboard has a nice feel to it and has plenty of travel for such a small device. It has a USB-C port, a standard USB port, a headphone jack, and a mini HDMI port. In such a small device, they couldn’t fit a trackpad in, but instead has one of those lovely nipples common in older laptops, or IBM ThinkPad’s of today.

Overall, I am very impressed with the build quality.

Usability

As for usability, it works very well. The screen is easy to read and not too small, the trackpad works well if your used to these kinds of things, and the keyboard is much better than I was expecting. I had read a lot of reviews about the keyboard being a little difficult to get used to, but I have warmed to it very quickly. The layout is a bit non-standard, with the tab key being in an unusual place, but I am quite used to it, and can type at a reasonable speed. The fan is a bit audible, but nothing too bad, certainly not the loudest I have experienced. I find myself using a mixture of the nipple, and the touch screen (did I not mention it also is touch enabled) to navigate around, and the size of the device means it can be put in your pocket (it still needs a largish pocket). I don’t normally use standby on laptops, but with this, I find I am more inclined to just shut the lid, so I can resume where I left off.

Portability

As already mentioned, it does fit in a pocket, maybe a jacket pocket, but you would not want to stick it in your jeans pocket. It’s the perfect size though for either throwing in a bag, your coat pocket, or even just carrying it. Its no bigger than a paperback book if you hold it in your hand.

It certainly has allowed me to take a computer with me where I would not normally take a laptop, which I like.

Battery life

So far, battery life has been very good. Its rated at up to 12 hours which is most likely very unrealistic. I have not actually done any timings yet, but it feels like I am getting around 6 hours of use. Maybe about 2 days of regular quick bursts of use. The good thing is that it charges over USB-C, so, if I am on the go, I can keep a battery pack at hand to keep it going for longer and can even charge it with a decent smartphone charger. No external power bricks required.

When putting it in to sleep mode, it seems to lose around 1-3 percent of battery overnight. It should be noted though that I was experiencing a few random restarts when in sleep mode, until I set Windows 10 to disable Wi-Fi when asleep.

What I use it for

My use so far has been to do a bit of writing on the go, or when away from another PC’s. So, writing blog posts, stories etc. I also have Visual Studio for some on the go development, which works surprisingly well. The usual Office and Outlook is also present.

Oh, and how about a bit of gaming. Now, I know I am not going to playing PC games on the keyboard (and its too much clart on to connect a Bluetooth controller to it (which does work)), but, how about a bit of retro ZX Spectrum emulation. This works well, and playing some old spectrum games on the keyboard reminds me so much of the good old days.

And how about a quick ZX Spectrum gaming video!

 

DevOps home server – part one – the equipment

Ah, DevOps, such a buzz word now.  It seems that everyone wants to bring Operations and Development together, in a harmonious gathering of intellectual minds.  To get in on the action, I wanted to do some hands on development, with a little saucy operation to go with it, and so wanted to experiment with some home server shenanigans.

Why bother, I hear you say, why not just use the existing cloud services I hear you cry.  Well, I really don’t have an explanation, other than to say, why not.  Sometimes, a workplace environment may not be in a position to use the various cloud services, and may have to host everything themselves, so its worth having a bit of experience with such a situation.  So, I bring to you my experience of setting it all up, using Windows Hyper-V.

Firstly, a little bit of background as to what I already had, before I get in to the most recent information with regards to my little home development environment.

Continue reading “DevOps home server – part one – the equipment”

Enabling OneDrive when some pesky admin has disabled it

On my corporate machine, it turns out that the powers that be decided to disable OneDrive.  I have a personal 1TB OneDrive account which I use for all manor of things, and I was not happy about this, so I set upon trying to find out a solution.

I found two useful things.

  • Local Group Policy Editor

    In the Local Group Policy Editor (Control Panel, Local Group Policy Editor, or just search for group in the Cortana Search Box), look for :

    Computer Configuration\Administrative Templates\Windows Components\OneDrive

    Find the key :

    Prevent the usage of OneDrive for File Storage

    And disable it.  If it is not configured, still disable it.

  • Windows Registry

    In the Registry Editor, look for :

    HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\OneDrive

    Find the keys (one, or both, depending on what appears) :

    DisableFileSyncNGSC
    DisableFileSync

    Change those values to 0.

 

Doing both of these may be enough to allow OneDrive to run again.  However, you may find that upon next boot, or if you connect to your corporate VPN, one or the other may have reverted back.

To try and fix this, within the Registry Editor, I have modified the Permissions on the Key Container (the folder : HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\OneDrive) and denied access to if for some of the users and groups.  I think it has worked, but time will tell I suppose.