Staying Healthy When You Sit On Your Butt All Day

I was asked a while back how I manage to stay healthy when I don’t really exercise and develop all day long. Well I do a number of things that help me and I will cover a couple of them here.

The Problem

If like me you get up and get ready for the commute into work, then work all day to finish off commuting back home to look after the household and all that is needed for your family. This lack of any exercise coupled with a sedentary life can lead to weight gain even though you may not be shoveling the junk in your mouth. Here in the UK it is advised that a male should consume around 2500 calories a day and a woman around the 2000 mark. But if you are doing desk work and not manual labor then this should be more like 2000 for men and 1800 for women based on an age of 40.

The lack of exercise and a typical developers life has lead me to gain weight over the past 10 years. I have tried all sorts of diets and exercise regimes to get my weight down with no luck until I started a combination of a type of diet and HIIT style exercise.

Staying Healthy When You Sit On Your Butt All Day

The two main techniques I use are the 8 hour diet and the 7 minute workout.

The 8 Hour diet

At its core the 8 hour diet [1] allows you to only eat during the 8 hour period and fast for the remaining 16 hours. It comes from ‘The 8-Hour Diet: Watch the Pounds Disappear Without Watching What You Eat!’ by David Zinczenko and Peter Moore’ and has been hailed as the miracle diet by many magazines and newspapers. Some publications state that you can eat whatever you want and still loose weight. Well a lot of what is written is just garbage. The 8 hour diet is based around intermittent fasting and is know to aid in weight loss as during the fasting period your body starts to burn the fat stores.

This alone can help you reduce weight without drastically changing your lifestyle, however to help boost the weight loss keep to a sensible diet and stop eating the junk.

The 7 Minute Workout

It is not always possible for me to get down the gym for a jog, so on some mornings I do the 8 minute workout [2].l This workout is a form of HIIT or High Intensity Interval Training and as you guessed can be done in just under 10 minutes. You don’t need any gym equipment and if a step or small chair is to hand you can use that for one of the exercises. It is quite intense and took me  a while to get through the whole sequence without collapsing half way through with exhaustion. The exercises are:-

  • Jumping Jacks
  • Wall Sit
  • Push Up
  • Abdominal Crunch
  • Step Up Onto Chair
  • Squat
  • Triceps Dip On Chair
  • Plank
  • High Knees
  • Lunge
  • Push Up and Rotation
  • Side Plank

Calorie Counting and Exercise Apps

Being a Microsoftie of course I have a Windows Phone and use an app called ’7 Minute Workout’ by 11latoa and track my calories by using the MSN Health & Fitness app. The latter allows me to keep my data up to date by using both the app and the website.

The results?

I have been trying to loose weight for about 3 years now and the combination of these two techniques are probably the best I have done to date. But everybody is different with different metabolisms and life style, so what works for me may not work for you.

Happy codeing

References

[1] The 8 Hour Diet by David Zinczenko

[2] ‘HIGH-INTENSITY CIRCUIT TRAINING USING BODY WEIGHT: Maximum Results With Minimal Investment‘ ACSM’S Health & Fitness Journal: May/June 2013 – Volume 17 – Issue 3 – p 8–13

Posted in Personal, Practices

Charms Are Still In Windows 10, But For How Long?

Windows 10

Right so I got the name completely wrong in my last post, I will admit that straight away; talk about a curve ball.

I have been having a play around with the technical preview of Windows 10 and I am liking it a lot. I believe it is definitely an easier migration path for enterprise users still on XP. Is the reason why Microsoft went from 8 to 10 because of the theory that enterprises have a tendency to miss out on a release when doing their client migrations. So going from XP to Windows 7 and missing Vista and going from Windows 7 to Windows 9 or in this case Windows 10. Who knows.

Charms are still there in Windows 10

There was a rumor going around in the software development community a while back that Charms will be disappearing in the next Windows release. As this image shows, they are still there.

charms

 

However if you have a Store app open on your desktop and use the same key combination of Windows+C, then you also get access to a lot of the same functionality within the app.

win10settings

 

Why is this such a big deal

If you are developing Windows store apps, you need to be sure that what you are coding will be supported in future Windows releases. If you are adding functionality that allows your users to change app settings, they would now be accessible from both the Charms and context menu in the app. Maybe the Charms will disappear by the time Windows 10 gets its full release some time in 2015. At least this way all that work doing app settings fly outs will not go to waste. The other option would be to add the same functionality to a bottom menu in the app, similar to what you do in a Windows Phone app.

 

Happy coding

Posted in Enterprise, Windows, Windows 8

The Next Version of Windows Will Be…Windows

Windows 9 aka Threshold

Just a day to go before more details are released about the next version of Windows and I thought I would have a guess at the name.

Based on this image of Terry Myerson from this link:-

http://www.wpcentral.com/microsofts-operating-system-leader-teases-new-windows-name-ahead-tuesday-reveal

I have done some serious forensic image processing and in the end completely guessed that the Windows text will be centrally aligned.

On my monitor and scaling in Paint.Net there is 156 pixels on the left hand side and just over 156 pixels on the right with no room left for any other lettering or wording as this image shows.

windows

So there you go, its just going to be Windows from now on.

 

Happy codeing.

 

 

Posted in Windows 8, Windows Phone

Access IIS Express Website From Remote Machine

IIS Express Run From a Remote Machine

Sometimes running a web application using IIS Express using localhost is fine, but if you want to use the IP address and port to access it from another machine then you need to configure IIS Express. For example if you see this error

Invalid hostname

Invalid hostname

You can get to the IIS Express settings applicationhost.config by going to IISExpress\config in your documents folder.

The important section of the config file are the sites listings

<site name="WebApplication1" id="45">
<application path="/" applicationPool="Clr4IntegratedAppPool">
<virtualDirectory path="/" physicalPath="C:\visual_studio_projects\WebApplication1\WebApplication1" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:60106:localhost" />
</bindings>
</site>

To access it from another machine, you need to add an extra entry for the binding like this:-

<binding protocol="http" bindingInformation="*:60106:192.168.234.12" />

But after restarting IIS Express which is accessible from the try icon you may get this

 

Visual Studio error

Visual Studio error

 

Usually all you need to do is start a command console as administrator and run this command:-

netsh http add urlacl url=http://192.168.234.12:60106/ user=everyone

To delete the same urlacl run this:-

netsh http delete urlacl url=http://192.168.234.12:60106/

But sometimes that does not always work and you still cannot run the web application by its IP address. The other approach is to run Visual Studio as administrator. This can be tedious every time you start Visual Studio up, so find its executable which is usually under:-

C:\Program Files (x86)\Microsoft Visual Studio {version}\Common7\IDE

Right click the devenv.exe icon and choose properties. The select the compatibility tab.

Change the Privilege Level to run as administrator like this:-

Visual Studio .exe properties

Visual Studio .exe properties

 

You can also choose to change this setting for all users if you wish.

Now you should be able to run your web application from another machine such as virtual machine.

 

Happy coding

 

 

Posted in CodeProject, MVC, Practices, Web