Sunday, June 22, 2008

XmlSerialization Reference Types vs Value Types.

Why are Specified properties generated for few DataTypes when using XSD.EXE or WSDL.EXE

Answer:
They are generated only for valuetypes that have there minOccurs property set to zero, becuase valutypes cannot be set as null.

Monday, March 24, 2008

VS 2008 and WCF Adapter SDK.

As far as i am familiar, microsoft has not yet released a WCF Adapter Template for VS 2008.
I went a head and installed VS2008 on a machine which already had the following
1)VS2005
2)WCF Adapter SDK.
After installing VS2008 when i tried to use the add adapter reference in a project an error was thrown "No Adapters were installed on the machine", i realized that VS 2008 overwrites the machine.config's Service Model Section,
So the fix is to add all the client, binding element extension and bindingelements in servicemodel section again.

Thursday, February 7, 2008

Add Visual Studio Post-Build Events.

Update: a much better alternative.
http://www.elumenotion.com/Blog/Lists/Posts/Post.aspx?ID=23


One of the most under used features of Visual Studio is the post and pre build events.......

Example: Deploy the assembly to gac and copy the .pdb files in to the assemblies gac directory.
before this gac the assembly and navigate to its (gac) folder from "C:\WINDOWS\Assembly\GAC_MSIL\Assembly NameSpace

1) create a bat file with the following and save it in the bin\debug\postbuild.bat

"C:\Program files\Microsoft Visual Studio 8\SDK\v2.0\Bin\GacUtil.exe" /i Assembly Name.dll/f

xcopy Assembly Name.pdb C:\WINDOWS\Assembly\GAC_MSIL\Assembly name space\1.0.0.0__Assembly Public Key Token\

2) Right click the project select properties.

3) Navigate to Build Events

4) In the post build event text box enter the following

call "project path\bin\debug\postbuild.bat"

5) Rebuild the solution ...

Hope this helps