Charles Young

  Home  |   Contact  |   Syndication    |   Login
  104 Posts | 41 Stories | 295 Comments | 407 Trackbacks

News

MVP - Microsoft Most Valuable Professional

Article Categories

Archives

Post Categories

Image Galleries

Alternative Feeds

BizTalk Bloggers

BizTalk Sites

CMS Bloggers

Fun

Other Bloggers

SharePoint Bloggers

Utilities

WF Bloggers

Some time ago I published a utility on GotDotNet.com which dumps the temporary C# source code files generated by BizTalk during compilation. The utility works quite well, but cannot always dump all the files because it is unable to prevent BizTalk from deleting files once compilation is complete. BizTalk sometimes gets there first, removing the temporary files before the utility has a chance to copy them to the target dump location. Another problem is that the files have meaningless names, and are therefore difficult to trace back to the corresponding BizTalk artefacts.

The utility is cool…but quite unnecessary. It turns out that Microsoft has implemented an undocumented registry setting to control the generation of C# files. Create a key called BizTalkProject at the following location:

HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\7.1

Next, create a DWORD value called GenerateCSFiles. Set the value to 1 (or higher). Restart Visual Studio, load a BizTalk project and re-compile. Now take a look at your project folder. Some of you may be disappointed to know that GenerateVBFiles and GenerateJSFiles are not supported.

Enjoy!

posted on Saturday, January 22, 2005 12:01 AM

Feedback

# re: BizTalk Server 2004: Generating C# source files 1/27/2005 12:17 AM tareq muhammad
I did, but I can't find the .cs files, where are they are generated,

# re: BizTalk Server 2004: Generating C# source files 1/27/2005 9:02 AM Charles Young
They should be in your BizTalk project folder. They are not included as part of the BizTalk project, so you will either need to browse to the folder using Explorer, or use the "Show All FIles" button in Visual Studio's Solution Explorer.

# re: BizTalk Server 2004: Generating C# source files 1/29/2005 11:50 AM Tareq Muhammad
it works thanks

# re: BizTalk Server 2004: Generating C# source files 2/5/2005 6:13 PM David Stampfli
Great tip. Thanks.

You're right, by the way, about some of use being disappointed about the lack of a GenerateVBFiles option.

# re: BizTalk Server 2004: Generating C# source files 5/26/2005 11:17 AM Sanket Bakshi
Great tip !!
Could get the code successfully.
However it generates blank files for some orchestrations.

Any ideas ?

# re: BizTalk Server 2004: Generating C# source files 5/26/2005 3:11 PM Charles Young
It's a 'feature'. The code generator, for reasons best known to itself, often decides to pack the code for multiple orchestrations into a single file, but continues to create files for every orchestration! Hence, you get orchestration files that are empty. All the code is there, but you have to go looking for it.

# BizTalk 2004 Debugging Tip 6/6/2005 4:22 PM CedarLogic
Symbolic Debugging for Orchestrations...
http://www.traceofthought.net/PermaLink,guid,75e22eec-348d-4880-bea4-6c7a5316e2dd.aspx...

# re: BizTalk Server 2004: Generating C# source files 10/18/2005 9:32 PM AndyM
Works for BizTalk 2006 Beta 1 too... just remember to change that VS version.

# BizTalk Server 2004 not able to load project 11/18/2005 3:41 AM Arun Shrivastava
there is error that not able to load project and btproj component is missing plz help me urgently

# re: BizTalk Server 2004: Generating C# source files 1/8/2007 10:35 AM haja
This is not working. No code generated. I am using it in terminal server environment.

Post Feedback

Title:
Name:
Email: (never displayed)
Url:
Comments: 
Please add 7 and 5 and type the answer here: