Tuesday, October 2, 2012



Using Javascript for most kinds of projects these days means anything that makes life easier has got to be welcome. Most of my development time is spent using Visual Studio so anything that helps me build better Javascript within Visual Studio is doubly welcome.

Type Script

Monday, July 11, 2011

Asp.Net MVC ViewData Not Declared


Hopefully this will help somebody else.

In a new project which uses ASP.net MVC, VB , Entity framework and razor I kept getting the following when running the application and connecting to my controller..

BC30451: 'ViewData' is not declared. It may be inaccessible due to its protection level.

Various hits simply suggested that the protection level was wrong – i.e private not public etc.

The view is a strongly typed view using ModelType of an entity class found in a separate DLL i.e my Datalayer.

Non EF objects were fine.

Eventually I created some simple projects from scratch with the minimum amount of anything possible. One entity with one property , trivial controller etc.

Still no luck

Finally I tried creating a c# project which gave me a useful error message straight away along the lines of you need to reference System.Data.Entity …..

Adding  <add assembly="System.Data.Entity, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> to the assemblies section of the web.config solved the problem for the c# project and back in my original VB project which now proceeds full steam ahead.

It seems reasonable now but the message should have been present for VB!

Monday, May 16, 2011

Audit Log Reports

There are various posts about enabling Auditing in SharePoint 2010 but after following these the ‘Audit Log Reports’ link within site collection settings was not present on my server. The reason is that the Reports feature needs to be activated at the site collection level.

Tuesday, May 10, 2011

IIS Value does not Fall within Range


Yesterday I upgraded an ASP.Net 2.0 Web application to .Net 4.

I copied the original to a new physical directory and set up the Virtual Directory/ Application in IIS. This is all on Windows 7. I modified the vbproj file and started visual studio. The upgrade wizard started then I was informed that the Virtual directory did not exist.

I should have stopped here and worked out what was wrong but  instead I answered yes to Visual Studio 2010’s offer to create the Virtual Directory. Laziness costs!. All seemed well. I finished the application upgrade , made some changes and ran it through the debugger. No problem. This morning I started my laptop and went to run the same application again. ‘Unable to connect to Web Server’. Looking in IIS the Default Web Site had not been started. hen I tried to start it I received ‘Value Does Not Fall Within Expected Range’.

The Windows event log told me which Virtual Directory was at fault.

I removed the Virtual Directory using IIS manager but it still didn’t start.

Opening up the ApplicationHostConfig file in c:windows\system32\inetsrv folder showed that the entry at fault was the one Visual studio had created. In the name of the Virtual directory were spaces

My manually created name was, for example, ‘My App’ but in the file I found ‘My%20%App’ – the entry added by Visual Studio. Removing the %20% fixed the problem.

Wednesday, April 27, 2011

A Good Day

A nice way to start the day is getting an email like this
Congratulations! We’re pleased to inform you that your contributions to Microsoft online technical communities have been recognized with the Microsoft Community Contributor Award.

Tuesday, April 5, 2011

Missing Email Notification Option in Tasks and Issues

While preparing for a demo to a prospective client I set up a new VM with SharePoint Server Standard Edition installed. Part of the demo/proposal was to show a workflow based on the clients requirements. One feature I intended to use was that when a new issue was created the new assignee would automatically be notified by email. This is built in functionality and is available to be switched on within List Settings –> Advanced Settings however the option is only present if you configure outgoing email settings on the server Smile

Sunday, February 20, 2011

This site has no title


Came across this problem recently on a heavily branded SharePoint Server site that had a blank site title – admittedly fairly rare.


Within the search centre on the results page the rightmost icon above allows you to add a location to the Windows 7 explorer favourites. From then on you can start searches in SharePoint without leaving Explorer.

click on the Icon You should then see a screen like this.


If you get an error ensure RSS is switched on for the site collection.

very neat Smile

However if you see something like this


Notice the file name is corrupt – add a title to the site and it works again as expected.