Thursday, March 29, 2007

SQL Server 2005 – SP2 available

We can *officially* run SQL Server 2005 on Vista... ;) All of those days of reading messages about SQL not being supported in Vista are finally over.!

Here is the query to determine your version of sql:



SQL Server 2005


SQL 2005 with SP1


SQL 2005 with SP2

You can download the SP2 at the SQL Server 2005 SP2 Download Page.

Wednesday, March 28, 2007

Free book on Building Composite Applications - OBA

With the release of Office 2007 and the whole enterprise suite, there seems to be a lot more buzz on the net about creating Office Business Applications (OBAs) to integrate enterprise business. This integration revolves around the idea of the ESB, which of course Biztalk seems to be the best implementation of it. IMHO. ;)

Developing in Sharepoint 2007, Infopath 2007 and Biztalk 2006 seems to fall into this category. There is a book written that Microsoft has made available for free download. Here is the link to Mike Walker's blog. He is one of the authors of the book. You can download the book here.

According to his blog, the LOB (Line Of Business) for loan originations will be out pretty soon. And this LOB will contain all of the files needed to implement the Loan Origination Solution. Including guidance package, enterprise blocks, etc. Nice. I can't hardly wait to start playing with this.

I like how Microsoft is leading the way by providing Best Practices (Enterprise Library) and Guidance Packages(GAX) that developers can follow when implementing enterprise solutions that have reusability and extensibility.


Sunday, March 25, 2007

Cincinnati Code Camp 2007

Original Plan:
  1. Get Up at 4:00am
  2. Meet James and Monish at 4:30am at the office
  3. Pick up Alexi at 5:00am at the Stringtown exit
  4. Arrive at Cincinnati at about 6:30am
  5. Go to IHOP for breakfast.
  6. Arrive at Code Camp before 7:30am to help out on the registration
Actual Plan:
  1. Phone call at 4:45am from Monish.
  2. [2-5] same workflow
  3. Arrive at Code Camp at 7:45am.
Mental Note: when you are setting your alarm you should make sure it is setup for the correct day. I set my alarm for 4am on FRIDAY... :(

To make up for the lost 30 minutes, I was doing about 74.6 miles/hr down on I-71 South. We make it to Cinci at about 6:50am. However, finding the IHOP was a little bit more complicated than we expected. Google sent us driving through neighborhoods and dead end streets for a while. Finally we made it to the IHOP and the Code Camp.

1st Session: Missed it [front registration duty]

2nd Session: Getting to know Generics by Dustin Campbell
Dustin was showing some of the gotchas using generics. One of the main point he was try to make was that sometimes developers do not know what else is out there and use Generics for all return values. He explained about a couple of namespaces which will return Read-Only generic types, which are safer for public interfaces.

3rd Session: Real World Sharepoint by Jim Holmes
What can I say? He is good.! Jim was doing the Sharepoint 2007 presentation yesterday at DevCares, and today's presentation was not a repeat.! One thing that I learn, is that the BSOD is still available in Windows Vista.! Jim got a BSOD right at the beginning of the session.! :)

4th Session: Intro to XNA by William Steele
Bill's presentations are always amazing. I have a bigger interest in the XNA Development Toolkit, since I am volunteering some of my time to teach kids about programming. So this knowledge will compliment my presentations. I am using Kids Programming Language, and the way XNA works, it seems that this will be an awesome transitions for kids that are captivated by game development and want to move on to more advanced topics.

5th Session: Intro to Robotics by William Steele.
This was by far the most fun presentation I have attended in a long time. The concept with the Microsoft Robotic Studio is almost the same: Microsoft is providing most of the skeleton/framework code for you, so that you can concentrate on the actual code for your robot and not how the robot works.

6th Session: Real World Agile by James Avery
His session was in the same format as the Open Spaces at CodeMash. The only difference was that the topic was defined by James and not the audience. But the 2-way interaction was there and it was good. Good questions and good suggestions from the audience, kept the presentation going past the time. To the point that they were tearing down the wall for the closing session while James was still talking.! funny.

Overall, I think that the Code Camp was a very nice local event. There were plenty of drinks till the end of the day. Food as expected in a conference. It was nice being part of the developer community. I will definitely come back next year. Kudos to Mike Wood and all of the volunteers there, they did an awesome job.

Wednesday, March 21, 2007

Cool Vista Secrets

I have found the site of Tim Sneath (Vista Technical Evangelist). He has posted a couple of hidden treasures that you can find on Vista. It is just AWESOME.

Here is the link:

My favorite secrets:
#4: Disabling UAC

#1: Open comand prompt

#2: Copy as path

#8: Zoom in Explorer.

#11: Deleting the Undeletable
nice, very nice... :)

Tuesday, March 20, 2007

Guidance Automation Toolkit Installation Failure on Vista

When trying to install the Guidance Automation Toolkit under Vista, you might encounter this error:
The installer has encounter an unexpected error installing this package. This may indicate a problem with this package. The error code is 2869.
This is an RTFM issue. ;) According to the documentation of December 2006, it mentions that this error is because of the UAC (User Account Control) of Vista. They also provide the work around: Run the MSI installer from a VStudio Command prompt that has elevated privileges (Run as Admin).

To install the Service Factory on Windows Vista

1. On the taskbar, click Start, point to All Programs, point to Microsoft Visual Studio 2005, and then click Visual Studio Tools.

2. Right-click Visual Studio 2005 Command Prompt, and then click Run as administrator.

3. Using the Change Directory (cd) command, navigate to the folder where the .msi file is located. For example: C:>cd users\me\downloads.

4. Run msiexec.exe using the following syntax.

msiexec /I "GuidanceAutomationToolkit.msi"

5. Complete the remainder of the installation as described in Installing the Service Factory.

the path to these set of instructions can be found on the CHM file:
Web Services Software Factory - December 2006
----Installing the Service Factory

--------How to: Install the Service Factory on Windows Vista

Thursday, March 15, 2007

GUID should contain 32 digits

If you are calling a Store procedure that accepts GUID's as parameters, you will need to initialize those parameters to a valid GUID, before executing the ADO command.

This is the error you will find on the event log:

Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).

to solve this, you can either initialize the GUID to Empty:
GUID paramGUID = new GUID.Empty();
or set the parameter to the string:
GUID paramGUID = new GUID("00000000-0000-0000-0000-000000000000");

Wednesday, March 14, 2007

Required Permissions on Web Service Factory

If you get this error, when trying to deploy your ASMX web service factory, it could be because of the trust permission. To fix this problem, open your web.config and anywhere inside the <>,
add the following:
< level ="Full" originurl="">
and it should work.

Server Error in '/XYZServices.Host' Application.

Required permissions cannot be acquired.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Security.Policy.PolicyException: Required permissions cannot be acquired.

Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:
[PolicyException: Required permissions cannot be acquired.]
System.Security.SecurityManager.ResolvePolicy(Evidence evidence, PermissionSet reqdPset, PermissionSet optPset, PermissionSet denyPset, PermissionSet& denied, Boolean checkExecutionPermission) +2738437
System.Security.SecurityManager.ResolvePolicy(Evidence evidence, PermissionSet reqdPset, PermissionSet optPset, PermissionSet denyPset, PermissionSet& denied, Int32& securitySpecialFlags, Boolean checkExecutionPermission) +57

[FileLoadException: Could not load file or assembly 'Microsoft.Practices.ObjectBuilder, Version=1.0.51205.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Failed to grant minimum permission requests. (Exception from HRESULT: 0x80131417)]
System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) +0
System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +211
System.Reflection.Assembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +141
System.Reflection.Assembly.Load(String assemblyString) +25
System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) +32

[ConfigurationErrorsException: Could not load file or assembly 'Microsoft.Practices.ObjectBuilder, Version=1.0.51205.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Failed to grant minimum permission requests. (Exception from HRESULT: 0x80131417)]
System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) +580
System.Web.Configuration.CompilationSection.LoadAllAssembliesFromAppDomainBinDirectory() +203
System.Web.Configuration.CompilationSection.LoadAssembly(AssemblyInfo ai) +45
System.Web.Compilation.BuildManager.GetReferencedAssemblies(CompilationSection compConfig) +178
System.Web.Compilation.WebDirectoryBatchCompiler..ctor(VirtualDirectory vdir) +199
System.Web.Compilation.BuildManager.BatchCompileWebDirectoryInternal(VirtualDirectory vdir, Boolean ignoreErrors) +37
System.Web.Compilation.BuildManager.BatchCompileWebDirectory(VirtualDirectory vdir, VirtualPath virtualDir, Boolean ignoreErrors) +445
System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) +77
System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) +596
System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) +76
System.Web.Compilation.BuildManager.GetVPathBuildResultWithAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) +52
System.Web.Compilation.BuildManager.GetVPathBuildResult(HttpContext context, VirtualPath virtualPath) +36
System.Web.UI.WebServiceParser.GetCompiledType(String inputFile, HttpContext context) +44
System.Web.Services.Protocols.WebServiceHandlerFactory.GetHandler(HttpContext context, String verb, String url, String filePath) +71
System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig) +328
System.Web.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +139
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +146

Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.210

Monday, March 12, 2007

Intellisense on Infopath 2007

This is a very useful post from the Infopath team blog about enabling IntelliSense on your Visual Studio IDE.

Enabling InfoPath InteliSense Documentation in VSTA and Visual Studio.

Sunday, March 11, 2007

How to pre-compile an ASMX web service


aspnet_compiler -? to view options. The ones I used are:


Virtual path of app (i.e. “/MyApp”)


Physical directory of the app


Location of strong name key file (snk)


Overwrite previous content

So for example, we have a web service named SoxAuditWss, if we need to move this web service to the QA machine, we could pre-compile it by using the following command:

-v /SoxAuditWss
-p "C:\vsprojects\Services\SOXAuditWSS"
-f "C:\vsprojects\Services\bin"
-keyfile "C:\vsProjects\Services\BTS\yourkeyhere.snk"

Dont forget to add the Key to the compilation step. This is necessary if you are moving this web service to a different machine.

Thursday, March 08, 2007

Exam 70-235

I have passed the Microsoft exam 70-235. Now I have bragging rights to Biztalk, having passed all 3 exams. :D

70-230: Designing and Implementing Solutions with Microsoft® BizTalk Server 2000, Enterprise Edition.

74-135: Developing EBiz Solutions Using Microsoft BizTalk Server 2004

70-235: TS: Developing Business Process and Integration Solutions using Microsoft® BizTalk® Server 2006

Monday, March 05, 2007

Hidden Emoticons

This is a cool initiative from Microsoft. It is not like those old spams about forwarding a message to all of your friends to get money from Microsoft, or to send email to stop charging for the use of Hotmail.

Read it at the MSN messenger site:

My favorite is the American Red Cross. *red+u , but I think I will be selecting one of each every week this month...
Text Code Cause
*red+u American Red Cross
*bgca Boys & Girls Club
*naf National AIDS Fund
*mssoc National Multiple Sclerosis Society
*sierra Sierra Club
*komen Susan G. Komen for the Cure
*unicef The US fund for UNICEF

Thursday, March 01, 2007

Returning GUID from STP

Calling a store procedure to return a GUID:

PROCEDURE lookupGetEquipmentGUIDFromDomainName
@piDomainName nvarchar(50)

SELECT UPPER(EquipmentGUID) as EquipmentGUID
FROM Equipment
WHERE DomainName = @piDomainName

on the ADO.NET, make sure to get the .ToString of the object before converting it to a GUID type.

string s =
outEquipment.EquipmentGuid = new Guid(s);

This will assign the GUID coming back to a type GUID in the object.