UK Hosting Directory

Just another WordPress weblog

Information Filled Under ‘.NET’

ASP.NET 4.0 AJAX – Preview 4 – JavaScript Observer Pattern

In my last post on ASP.NET AJAX 4.0, we took a look at the new DataView ASP.NET AJAX control .  We saw that by using a DataView, we could easily bind data with JavaScript or declaratively with a few attributes.  In this post, we’ll look at another feature of the ASP.NET 4.0 AJAX Library, the Observer design pattern for plain JavaScript objects.  The pattern is implemented in the client side Sys.Observer class.  This feature is used internally within the new version of ASP.NET AJAX for live-binding and the DataView control .   Here we will be using Preview 4 of the ASP.NET AJAX Library, which can be downloaded from CodePlex .  Remember that these components are still in “preview” mode (meaning no Microsoft support), though they are usable at your own risk.  For more information, you can check out the license on CodePlex.  I highly recommend downloading the samples available for Preview 4, which are also available at CodePlex .  The samples give you a good look at what is coming.  In this post, we’ll take a closer look at the Sys.Observer class, witness the problems it solves, and take a look at a few examples.    A Quick Look at JavaScript Objects To this day, I still know developers who either don’t understand, don’t want to understand, or flat out loathe JavaScript.  I suppose this really has to do with it being totally misunderstood , but in a Web 2.0 world, a web developer should embrace the language.  Especially with wonderful frameworks like jQuery and the Microsoft AJAX Library  This section is a quick overview of JavaScript objects in case you aren’t familiar with them.  Objects in JavaScript can be described as hashtables, they are collections of names and values,  for example: // An empty object var person = {}; // Another way of defining an object var person2 = new Object(); // Adding a name/value pair (a local variable) person[ "firstName" ] = ‘Damien’ ; // You can also use the dot notation instead of subscript notation person.lastName = ‘White’ ; // And you can define objects using the object literal notation var person = { firstName: ‘Damien’ , lastName: ‘White’ }; This is by no means definitive. If you have JavaScript-phobia, you should start here . The Object Modification Problem Let’s say you have a simple object with a couple of properties.  Note that JavaScript doesn’t have properties as we know them in .NET, they are just local variables like those defined on the person object in the previous code snippet, however there are conventions for emulating them with functions.  Back to our simple object, let’s say that you need to be notified if the object changes.  Take the following snippet, note I’m using the jQuery in order to simplify the code (e.g.

Here is the original post:
ASP.NET 4.0 AJAX – Preview 4 – JavaScript Observer Pattern

Finding installed version, edition and service pack version of SQL Server

Today I wanted to find the version of SQL Server 2008 installed in my machine.  I did a quick search and the first support article from Microsoft had the answer to it http://support.microsoft.com/kb/321185 I just modified it a little bit with column headings so that if you are using it in an SP, returning it etc., it would help.  So the modified query is as below SELECT SERVERPROPERTY(‘productversion’) as ‘Product Version’, SERVERPROPERTY (‘productlevel’) as ‘Service Pack Version’, SERVERPROPERTY (‘edition’) as Edition If there are better/alternate ways, please post in the comments. Cheers !!!  

Read this article:
Finding installed version, edition and service pack version of SQL Server

How To: Adding MVC items to an ASP.NET Web Application

I’ve been experimenting with using ASP.NET MVC inside a standard ASP.NET Web Application (Web Forms).  I really like what’s been released with MVC 1.0 and can see places where existing apps would benefit from the features.  Plus, having just finished Professional ASP.NET MVC 1.0 from Wrox (see my book review ), I couldn’t wait to start using it.  The last chapter of the book , Chapter 12, entitled “ Best of Both Worlds: Web Forms and MVC Together, ” discusses configuring an ASP.NET Web Application to support the new ASP.NET MVC features.  Note that adding Web Forms to an ASP.NET MVC project template is much easier (meaning no configuration/reference changes), since ASP.NET MVC is built on top of the ASP.NET Framework.  Anyway, after referencing the required libraries, creating the necessary directories, and updating the web.config, you’ll find that templates for the MVC items (e.g. Controllers, Views), are missing as options.  Well after digging around on the web, I found a solution to the problem .  It involves editing the project file and adding a guid to the ProjectTypeGuids node.  Caution: Before you do this, make sure that you have ASP.NET MVC 1.0 installed on your machine, also BACKUP your project file before modifying it.  If there is a mistake in the file, Visual Studio won’t load the project properly.

See the original post:
How To: Adding MVC items to an ASP.NET Web Application

Some important links

Update for .NET 3.5 SP1 (Important if working with Dynamic Data) http://support.microsoft.com/kb/959209 ASP.NET Compilation Enhancement Fix http://code.msdn.microsoft.com/KB967535/Release/ProjectReleases.aspx?ReleaseId=2328   (for Windows Vista and Windows Server 2008) https://connect.microsoft.com/VisualStudio/Downloads/DownloadDetails.aspx?DownloadID=18157 (for Windows XP and Windows Server 2003) Microsoft .NET RIA Services May 2009 Preview http://www.microsoft.com/downloads/details.aspx?FamilyID=76bb3a07-3846-4564-b0c3-27972bcaabce&displaylang=en ASP.NET 4.0 in VS 2010 Doc    http://www.asp.net/learn/whitepapers/aspnet40 Some of them are a little old but thought worth putting them up. Cheers !!!

Read the original here:
Some important links

PPTs opening very slowly? – Check your printer drivers – Microsoft Office 2007 PowerPoint

Recently I seemed to have issues with opening PPT files.  I am running Office 2007 for a long time now and one of the things that I use most with respect to my work is PowerPoint files.  Over the last 2 weeks I saw a certain weird behaviour with PPTs specifically related to printer options. Every time, I try to open the PPT or unlock the system with the PPTs open, they try to print to my default printer.  The specific error message would state that the default printer could not be accessed.  I dismissed them couple of times and thereafter, the PPTs start working normally.

View post:
PPTs opening very slowly? – Check your printer drivers – Microsoft Office 2007 PowerPoint

Visual Studio 2010 and .NET 4.0 Beta 1 Download today

  After the tremendous amount of interest the VPCs of the Visual Studio 2010 and .NET 4.0 generated, the Beta 1 bits would be available for download for MSDN Subscribers later today.  The general public would also be able to download the bits starting this Wednesday. Visual Studio 2010 combines the power of .NET 4.0 and the tremendous enhancements done to areas such as Web Development, WPF as well as native development and provides the best so far platform for developers. While some of the features were available as v1 in .NET 3.5 SP1 as well as individual downloads over the last few months, with Visual Studio 2010, all of these are bundled into one install and has much richer integration support for many of what developers wanted.

Follow this link:
Visual Studio 2010 and .NET 4.0 Beta 1 Download today

ASP.NET Sessions at Tech.Ed India 2009

I am back from delivering Tech.Ed India 2009 , particularly the web platform track where I delivered three sessions across 2 days.  In addition, we also had Stephen Walther from the ASP.NET Team deliver sessions on ASP.NET 4.0, ASP.NET MVC and ASP.NET AJAX. Over the next few posts, I would like to get all the content that we discussed during Tech.Ed India and possible videos so that even if you missed the action over there, you could benefit right here.  To begin with, the sessions focussing on ASP.NET were ASP.NET 4.0 by Stephen Walther ASP.NET MVC by Stephen Walther ASP.NET Dynamic Data by Harish Ranganathan (that’s me) IIS 7.5, Server Core with ASP.NET – Windows Server 2008 R2 by Praveen Srivatsa ASP.NET AJAX by Stephen Walther VS 2010 Web Deployment features by Harish Ranganathan ASP.NET – A day in the life of an ASP.NET Request by Harish Ranganathan While bulk of the above require VS 2010 bits, to begin with, lets pick up the sessions which don’t require ex.-  The session on ASP.NET Dynamic Data.  In this post, I would specify the things to get started and cover up the actual content in the next post

Read the original here:
ASP.NET Sessions at Tech.Ed India 2009

Book Review – Wrox Professional ASP.NET MVC 1.0

Working primarily on web applications, I’ve focused most of my time on ASP.NET Web Forms since the very early betas.  Web Forms were truly a great revolution in the web world.  Once I saw the functionality when it first came out (when I was using ::shudder::  “classic” ASP), I couldn’t wait to start using it.  I began right away with ASP+, as it was called back in 2000 , abandoning Visual Interdev and ASP, yippee.  The release of Version 1.0 came out January 16, 2002, changing the way we work with the web. Flash-forward 7 years (9 from the early betas), and the programming world has changed.  With things like TDD (Test Driven Development), AJAX, JSON, jQuery, etc, and the complexity of web applications growing, sometimes Web Forms would get in the way.  To be fair, the Web Form framework is very robust and tries to be helpful, but sometimes we developers like to shoot ourselves in the foot.  One example that I’m sure many of you have experienced is trying to interface with a server-rendered element on the page.  Performing something like a document.getElementById(‘UserName’) in JavaScript doesn’t exactly work as expected when the ID of your textbox is now something along the lines of “ctl00_mainContent_LoginCtrl_UserName,” does it?  On this particular topic, ASP.NET 4.0 has a solution for this problem , but that isn’t the focus of this post.  The Client Id problem, is just one example of the framework “getting in your way.”  This is one of the many reasons behind the advent of ASP.NET MVC .  Having just finished Professional ASP.NET MVC 1.0 from Wrox, I’m a convert

Read the original post:
Book Review – Wrox Professional ASP.NET MVC 1.0

Best Public Speaking Tips and Techniques: Weekend Review [2009-05-09]

On Saturdays, we survey the best public speaking articles from throughout the public speaking blogosphere . This review features topics including: fundamental speechwriting techniques; tips for valedictory or commencement speeches; avoiding “waxy” words; the benefits of speaking slower; making public speaking fun; a plethora of tips for designing better visuals; logistics and preparation; overcoming public speaking fear; effective speech introductions; and tips for professional speakers.

Visit link:
Best Public Speaking Tips and Techniques: Weekend Review [2009-05-09]

Citywide Security Group Logo Brand Identity

Logo Category: Security Logos Logo Type: Iconic Logos Client Location: Chicago, IL 60641 Project Type: PLATINUM Brand Package Project Cost: $997 Project Summary: Citywide Security Group provides contract security guard service as well as private investigations. Located in Chicago, Illinois, CityWide Group ensures their clients get high quality and reliable security service

Continue reading here:
Citywide Security Group Logo Brand Identity

Microsoft Hosts Most Active Sites

Web analytics firm Netcraft ( www.netcraft.com ) is expanding on its web server survey by offering a dataset of the most active sites , giving a truly global analysis of web hosts. The firm explains that each website that is found on its monthly web server survey can be attributed to a hosting location using reverse DNS and IP address delegation information

Read more from the original source:
Microsoft Hosts Most Active Sites

ASP.NET 4.0 AJAX – Preview 4 – Client Templates

A little over a month ago, Microsoft released the fourth preview of ASP.NET 4.0 AJAX.  This is the new release of the Microsoft AJAX Framework that will be released with ASP.NET 4.0.  We’re getting closer to the RTM release of .NET 4.0 (hopefully later this year), so I figured this would be a good time to start posting about ASP.NET 4.0 AJAX.  There are some very exciting things coming along with ASP.NET 4.0, and the ASP.NET AJAX component is no exception.  The best news about ASP.NET AJAX is that you can start using it today without having to wait for the full blown ASP.NET AJAX framework.  Keep in mind that these components are still in “preview” mode (meaning no Microsoft support), though they are usable at your own risk.  For more information, you can check out the license on CodePlex. In this post, I’ll be talking about the client templates that can be found in the latest release.  Client templates are very powerful.  They are a key component for rich client-side applications.  Up until now, I have been using jTemplates , a client template solution plugin for jQuery.  If you aren’t familiar with jTemplates, check out Dave Ward’s article “ Use jQuery and ASP.NET AJAX to build a client side Repeater .”  jTemplates is really a nice plugin, but it’s a bit disconnected from the flow of the page.  Enter ASP.NET 4.0 AJAX and the DataView control. Introducing the Sys.UI.DataView Control The ASP.NET AJAX DataView (not to be confused with the ADO.NET DataView), is a new control that functions similar to a server-side repeater as you will see.  The first thing to note with the DataView is that this control operates without ASP.NET, meaning you can use this in any framework or even a straight HTML page.  This shouldn’t be too much of a surprise, since you can download the ASP.NET AJAX Library 3.5 as standalone scripts today.  Having said that, let’s start with an simple example that will just run in a standard HTML page.  For this first example, I will walk through declaratively setting up template binding.  Let’s get started… Want to follow along with the examples?

Link:
ASP.NET 4.0 AJAX – Preview 4 – Client Templates

Hive Five: Five Best Mind Mapping Applications | Lifehacker Australia

You can export charts as HTML, images, or text, and XMind comes a free account on XMind.net which allows you to share your charts online and embed them into blogs and web sites. and if you dont get this, re-read the pictures in the blog post ^^) Paul Little Khalil Brought to you by: Work Literacy

Read more from the original source:
Hive Five: Five Best Mind Mapping Applications | Lifehacker Australia

FatCow Email Review

Are you interested in purchasing FatCow Web Hosting ?  Well, now is a better time than ever to start using FatCow because they having a special promotion.  FatCow is selling a web hosting plan with 1500GB storage space, unlimited domain names, and unlimited email accounts for only $66 per month.  This promotion is a great deal, if you are looking to purchase web hosting, you should take advantage of this opportunity. Visit FatCow Web Hosting  Affordable Web Hosting Home Related posts: FatCow Review of FatCow.com FatCow Web Hosting  is a shared web hosting service.

Original post:
FatCow Email Review

Best Public Speaking Tips and Techniques: Weekly Review [2009-03-07]

On Saturdays, we survey the best public speaking articles from throughout the public speaking blogosphere . This week’s review features topics including: recently released speaking books; research tips for speechwriters; tips for inspiring speeches; benefits of humor in speeches; voice and gestures tips; PowerPoint advice; and how to use speaking to improve your business.

See the rest here:
Best Public Speaking Tips and Techniques: Weekly Review [2009-03-07]

Specialized Layout Panels for Silverlight

The layout system in Silverlight is, in my opinion, one of the key differentiators in presentation engine capabilities from HTML/CSS (on a related note, see my post long ago about my browser/scripting wish list and the references to need for core layout primitives). The Silverlight platform provides a set of out-of-the-box layouts like Grid, so you don’t have to simulate them with low-level absolute positioning, and float/clear css attributes.

Read more:
Specialized Layout Panels for Silverlight

Best Public Speaking Articles: Weekly Review [2009-02-07]

On Saturdays, we survey the best public speaking articles from throughout the public speaking blogosphere . This week’s review features topics including: new public speaking books; storytelling patterns; errors when ending a presentation; content vs. emotion; engaging your audience with questions; creating your own PowerPoint photos; and slides for color blind audiences.

The rest is here:
Best Public Speaking Articles: Weekly Review [2009-02-07]

Get your $2 worth of 3-D

With film producers and distributors boiling down the Stereoscopic film equation to the $2 mark-up for a 3-D film ticket, audiences are starting to air their demands for $2 worth of 3-D entertainment … The following article I wrote can be found in the excellent 3-D publication Veritas et Visus (3rd Dimension edition). I can highly recommend this online magazine for anybody working in the Stereoscopic industry, so do check it out: http://www.veritasetvisus.com/3rd_dimension.htm …As the average 2009 cinema ticket price in the US is $7.20 , that amounts to a mark-up of 22% .

View original post here:
Get your $2 worth of 3-D

Best Public Speaking Articles: Weekly Review [2009-01-24]

On Saturdays, we survey the best public speaking articles from throughout the public speaking blogosphere . This week’s review features topics including: Martin Luther King’s “I Have a Dream”; Barack Obama’s Inauguration Speech; importance of simplicity and brevity; personalizing your message for each crowd; and careers as a speechwriter or ghostwriter. Week in Review: Six Minutes Three feature articles mirrored the buzz in a great week for communication in the news: Speech Analysis: I Have a Dream – Martin Luther King Jr.

View original post here:
Best Public Speaking Articles: Weekly Review [2009-01-24]

Errors "Microsoft .NET Framework 3.5 installation has failed. SQL 2008 Setup requires .NET 3.5 to be installed." and "This server…

Today I had to work on a project which uses VS2008 and SQL Server 2008. I haven’t used SQL2008 but had used VS2008 a little bit. When I tried to install SQL2008 (Developer edition) got this strange error which says “Microsoft .NET Framework 3.5 installation has failed.

Read the original post:
Errors "Microsoft .NET Framework 3.5 installation has failed. SQL 2008 Setup requires .NET 3.5 to be installed." and "This server…

5 Speechwriting Lessons from Obama’s Inaugural Speech

Some will argue that Barack Obama’s Inauguration speech was not his most electric speech , or that it failed to deliver on unreasonably high expectations . Nonetheless, studying the speech provides five key speechwriting lessons that can help us all be better communicators. This article is the latest in a series of video speech critiques which help you analyze and learn from excellent speeches.

http://www-tc.pbs.org/newshour/rss/media/2009/01/20/20090120_obamaspeech.mp3

Read the original post:
5 Speechwriting Lessons from Obama’s Inaugural Speech

CodeIt.Right reviewed on MSDN Toolbox

With just a couple of days left this year, I wanted to share with you a great article in the MSDN Magazine Toolbox column this month on Improving Software Quality with Static Code Analysis Tools where MS MVP Scott Mitchell is reviewing Static Analysis Tools For .NET . Scott is comparing FxCop, StyleCop and CodeIt.Right: While FxCop and StyleCop pinpoint rule violations, the developer is still responsible for implementing these tools’ suggestions. CodeIt.Right from SubMain takes static code analysis to the next level by enabling rule violations to be automatically refactored into conforming code .

Read the original here:
CodeIt.Right reviewed on MSDN Toolbox

Standalone .NET Micro Framework Emulator

Upon a customers request I figured out how to use the .NET Micro Framework Emulator on a clear machine without Visual Studio 2008 and the .NET Micro Framework SDK 3.0 installed. Imagine a scenario where you might need to send your device application to someone for demonstration that does not have any MF hardware (because you are in the prototype phase and there is no final hardware yet) and he also is not a programmer having Visual Studio and the MF SDK installed.

View post:
Standalone .NET Micro Framework Emulator

Steve Lawson on social media for independent musicians

I went to London’s Vortex Jazz Club on Monday to catch the launch gig for the new Lawson/Dodds/Wood album, Numbers (pictured left, with guest sax player, Mark Lockheart). The thing is, I’d already had the album in digital form for a month or two — and not (a) because I nabbed a leaked copy off the net, or (b) because band member Steve Lawson (centre of photo) is a friend of mine. I paid the advertised price.

Read the original:
Steve Lawson on social media for independent musicians

Add a user programmatically to a User Group in SharePoint

        ///         /// Add a user to a Sharepoint group         ///         /// Login name of the user to add         /// Group name to add         private void AddUserToAGroup(string userLoginName, string userGroupName)         {             //Executes this method with Full Control rights even if the user does not otherwise have Full Control             SPSecurity.RunWithElevatedPrivileges(delegate             {                 //Don’t use context to create the spSite object since it won’t create the object with elevated privileges but with the privileges of the user who execute the this code, which may casues an exception                 using (SPSite spSite = new SPSite(Page.Request.Url.ToString()))                 {                     using (SPWeb spWeb = spSite.OpenWeb())                     {                         try                         {                              //Allow updating of some sharepoint lists, (here spUsers, spGroups etc…)                             spWeb.AllowUnsafeUpdates = true;                             SPUser spUser = spWeb.EnsureUser(userLoginName);                             if (spUser != null)                             {                                 SPGroup spGroup = spWeb.Groups[userGroupName];                                 if (spGroup != null)                                     spGroup.AddUser(spUser);                             }                         }                         catch (Exception ex)                         {                             //Error handling logic should go here                         }                         finally                         {                             spWeb.AllowUnsafeUpdates = false;                         }                     }                 }             });         }   Here in this method you have to set “spWeb.AllowUnsafeUpdates = true” to allow updating some sharepoint lists.

Continue reading here:
Add a user programmatically to a User Group in SharePoint

PDC 2008 CodeIt.Right License giveaway!

by Serge Baranovsky The best and the biggest MS developer conference Microsoft PDC 2008 edition is just few days away. We, of course, wouldn’t miss the great opportunity to meet and network with potentially 10000 developers. This year we will be giving away free CodeIt.Right licenses for those who manage to spot me in the crowd and talk to me about your favorite CodeIt.Right feature, what you don’t like about the product or help to prioritize the upcoming features

The rest is here:
PDC 2008 CodeIt.Right License giveaway!

Getting Started Video Editing

You only need a few items for getting started with video editing and you can be producing quality movies at home that you will be able to enjoy for many years to come. Maybe even produce a hit Hollywood movie. The basic items you need are a video capture card or DV card, the video editing software to edit, your computer, storage space on your computer and a camcorder, VCR, or you can display your movie on your computer screen

See more here:
Getting Started Video Editing