.NET and related technologies

Sleep# v3


Sleep# receives several downloads a day (over a hundred a month) from all over the world and I have had plenty of positive feedback – there are obviously lots of people who like watching videos/films before falling asleep!

Whether you use it as a “sleep after” VLC/Windows Media Player or for fading out music after a countdown or as simply a countdown timer, it has been a success far beyond the niche I anticipated.

Since the last version was released, the BBC have changed the way iPlayer works, and now it no longer comes out of fullscreen Flash after playback has finished. This has required the development of a new (universal) Flash detection method…

I have released a beta version of Sleep# v3 with experimental Adobe Flash detection – allowing you to send your computer to sleep/hibernate/screen off after watching a fullscreen Flash video, e.g. YouTube, BBC iPlayer and countless other streaming catch-up TV services.

There is also a log/history dialog allowing you to review Sleep#’s previous actions.

v3

As the (end of fullscreen) Flash detection is experimental I would welcome any feedback. Try watching a video (10 mins+) on YouTube (using Flash, not HTML5 video), make it fullscreen and leave it playing idly for at least 5 minutes. At the end of the video, Sleep# should trigger the grace period – fading the screen to black by default before triggering the sleep/hibernate/turn off display command. Alternatively you can turn the Flash Detection off if it is not required 😛

You can download v3 beta from the Beta folder at https://sourceforge.net/projects/sleepsharp/files/.

Advertisements

Sleep# v2


Gayan at Heckic Geek has reviewed Sleep# (review version 2.2.1) favourably.

Tray

Sleep# saves electricity (and fan noise!) by putting your computer into standby/sleep mode after full screen media playback. It is fully customisable and includes a grace period during which the screen slowly fades and you have the chance to abort the sleep process.

I’ve just released v2.3.0 which adds support for multi-monitor setups and Windows 8 (as long as you use a compatible media player – Windows Media Player or VLC). If you are running an earlier version I recommend that you make the upgrade Smile.

Sleep# can be downloaded from http://sourceforge.net/projects/sleepsharp/.


For the past couple of years I have worked with an educational psychologist on a literacy tutor, dubbed SPLAT, to create a solution for children with special educational needs and dyslexia.

The package consists of a handheld device and Teacher Control Panel software, shown below. Teacher Control Panel

SPLAT utilises the systematic/synthetic phonics method in various games for the student, records the results and generates reports (see below for an example) for each student. Each game can be individually tailored to the student’s specific needs. The most basic game, ‘Systematic Phonics Blend’, sounds out the three or more phonemes of a word, which the student blends in their head before selecting the corresponding image.

Spell Report 1Spell Report 2

The games are played on a refurbished hand-held device, with a touchscreen, stylus (like the Nintendo DS that many children are familiar with) and headphone jack.

The solution has been developed entirely in .NET, utilising technologies such as Entity Framework 4, Windows Communication Foundation and Windows Presentation Foundation.

When set up in a school, the Teacher Control Panel will recognise the teacher through their login and display the students in the class. It’s really simple to use when set up and should save time as the students can get on with the practice – little and often, on their own.

If this sounds like something you that would be of benefit to you, either as a teacher/SENCO or as an organisation, then please contact me.


Do you use your computer for playback of films, streamed TV etc. before going to sleep?

In these cases, your computers sleep functionality is suspended whilst the video is in playback.

Sleep# sends your computer to sleep after the playback of full-screen video, providing Windows has been idle for a predefined amount of time.

There is a grace period at the end of the full-screen video before sending your computer to sleep, allowing you to interrupt the process should you still be awake.

For this to work, after the video has played back, the video player should leave full-screen. VLC media player does this, as does BBC iPlayer among others. Please let me know your experiences – does it work for you?

Sleep# can be downloaded from http://sourceforge.net/projects/sleepsharp/.


There are many reasons why you may want to keep Google Calendar and Windows Live Calendar in sync. You might want to keep your phone calendar (synchronised via Google Calendar) in sync with multiple PCs with Outlook installed (via Outlook Hotmail Connector). You may also have multiple phones, some of which rely on Google Calendar, others which rely on Windows Live Calendar. Basically, if you use both of the services, it is a good idea to keep them in sync.

You will need:

  1. Microsoft Outlook (2003 or later, 32bit)
  2. Microsoft Outlook Hotmail Connector (32 bit)
  3. Google Calendar Sync

The key here is to make the Hotmail/Windows Live account the default data file in Outlook – it is this default with which Google Calendar Sync will synchronise. If you have other data files, it may be worth transferring your mail to Hotmail so that it is all in one place and deleting them so you only have one data file (synchronised with Hotmail) to manage. Data files can be managed via the File > Data File Management option in Outlook (or equivalent on the ribbon).

By setting the Hotmail/Windows Live account as the default, your rules will also work in Outlook 2003/2007 (they work regardless in 2010).

Let me know if you have any problems or found this advice useful 🙂


I have been looking for a good few hours this Easter holiday for an effective way of designing an entity relationship diagram (ERD) in Visio and transforming it into a real SQL Server CE (Compact Edition – e.g. a database embedded in a .NET application executable, executing with the application at runtime) database shell. Visio is an excellent diagramming tool for this purpose, but I was hunting for hours for an export button to export the shape details to a database or DDL.

Now I have found an effective solution, I thought I would share what I found in the hope that someone else find’s this useful – feel free to post a comment to let me know!

You will need:

  1. Microsoft Visio 2010 (any edition)
  2. Forward Engineer for Visio 2010
  3. Microsoft SQL Server Management Studio Express 2008

The setup version for the latest version (1.0.6) of Forward Engineer (http://forwardengineer.codeplex.com/) is 64bit, despite containing a 32bit/x86 add-on to Visio. If you run the setup.exe on 32bit/x86 Windows you will get the error message “The version of this file is not compatible with the version of Windows you’re running. Check your computer’s system information to see whether you need an x86 (32-bit) or x64 (64-bit) version of the program, and then contact the software publisher.” To get around this issue you will need to first extract the contents (e.g. using WinRAR) before running the enclosed 32bit installer.

If you already have SQL Server 2008 Express installed, you may have problems installing Microsoft SQL Server 2008 Management Studio Express. You will need to perform a new installation (as opposed to adding features to an existing one) and (re)install the service pack 2 update (available through Windows Update) afterwards.

You can then design your database in Visio, use the Forward Engineer ribbon add-in to check and output your database as SQL DDL and execute this SQL in SQL Server Management Studio Express.

If you are using SQL CE then you will need to read on…

Note that Forward Engineer outputs code designed for SQL Server Express, not SQL Server CE. You will therefore need to manually alter the DDL to remove the syntax which SQL CE doesn’t support (don’t worry, this isn’t much work).

You will need to remove any occurrences of the following syntax:

  • IF  EXISTS…DROP TABLE
  • CLUSTERED
  • CHAR (change this to NVARCHAR)
  • WITH CHECK
  • WITHOUT CHECK

You will also need to remove the table prefix e.g. [dbo]. before each table name. You may also need to add additional GO commands between ALTER TABLE commands.

Hopefully with these changes your script should execute, let me know if you have any problems or need further guidance Smile