Tag | Debugging Posts

When working with Visual Studio 2005 on Windows Vista and create web applications running out of IIS 7, you need to perform a few steps before getting it work. I had blogged about it, in my earlier post However, after performing all the above, you might still get "An authentication error occurred while communicating with the web server. Please see Help for assistance" when trying to create a website / debugging a website created using Visual Studio 2005 running on a Windows Vista with IIS 7. There ...
One of the first things we went over in my first computer science class was the idea of preconditions and postconditions for functions: what the caller should expect will be needed before and how the results will be after the call. We also discussed parameter validation, which I've found more and more to be important. Parameter validation is not only important for security purposes, but helpful in debugging scenarios when you wouldn't otherwise be sure that an exception is being generated because ...
Ok so my editor (VSE) is just a little off the latest, but hey, so am I! ... I just checked and I have version 7, they're now selling version 2007 ... so hard telling how far off I am. I know 2 years ago they no longer supported 7. Oh well... it's like an old pair of boots... it just feels right, and I see no reason to upgrade :) Back to the reboot thing. Running VS2005 finally at the office, and merging two huge projects. Now and again I try to rebuild and it poots telling me that it can't replace ...
I stumbled upon an excellent utility for WCF Testing that comes with Visual Studio 2008 - WCFTestClient. The tool is an simple way to test WCF clients HTTP and TCP bindings. Some things are not supported, however, for basic WCF Testing, this definitely beats the old ASMX test page. Note: Also check out the WCFSvcHost utility from Visual Studio to host an arbitrary WCF Service. Technorati Tags: Debugging, Development, Microsoft Office, Tips, Tools, WCF, Visual Studio Cross Posted from http://blog.tfanshteyn.com/... ...
Recently I discovered a tool that I had needed for a long time. Fiddler, a freeware product created and supported by Microsoftie Eric Lawson, can be used to debug HTTP traffic from any web browser (or client application). Here's how you can use it: 1. View/Analyze HTTP traffic. One of our web apps creates a new window and performs a javascript-driven auto-logon to a vendor application. When we reported an issue to the vendor, they started asking questions about whether we were using the correct version ...
Late Cream for today: Ink Drawing by Julia Lerman, Seema Ramchandani exposes EnableRedrawRegions, and Shawn Wildermuth exposes a Clipping Path Transform problem. From SilverlightCream.com: Silverlight and Ink: Drawing Another old post, this one from Julia Lerman. I found this while searching for an answer for someone on the forum about drawing complex objects. At first I thought this was simply (yeah right) an Ink drawing app, but there are multiple pages, and it becomes much more and very cool.. ...
I learned something new, relating to when/how to dispose CollectionView, but it comes after a series of steps of proving it. Along the way I learned some new stuff to, so I'll stagger them so it becomes easier to read & digest. This post will become the first one in this series (of 3 I think). I'm always somewhat wary about the automatic garbage collection nature of .NET, so every now and then I need to prove to myself that something is actually garbage collected. The technique I use is to create ...
Video Interview with Flash Guru Jesse Warden, Tim Heuer discusses issues surrounding moving files around in build folders, Steven Smith takes aim at Hyperlinks in SL 1.0, Shawn Wildermuth gives a workaround to some problems with the SL Template, Mike Taulty has a good ADO.NET/SL WebCase, and Michael Palermo has 2 WebCasts dealing with debugging SL and ErrorHandling in SL. From SilverlightCream.com: A Flash Guru Talks about Silverlight Jesse Warden, a hard-core flash designer met with the MS folks ...
Scott Guthrie[MSFT] announced the availability of .NET fx 3.5 library source code as promised. (Setup and how to use) Quote from the announcement: Specifically, you can now browse and debug the source code for the following .NET Framework libraries: .NET Base Class Libraries (including System, System.CodeDom, System.Collections, System.ComponentModel, System.Diagnostics, System.Drawing, System.Globalization, System.IO, System.Net, System.Reflection, System.Runtime, System.Security, System.Text, System.Threading, ...
Scott Hanselman beat me to the punch, but come Feb 14th, our latest and greatest edition of the Professional ASP.NET book is coming out. The book has a ton of new content and was exciting to put together - but man, did it take some serious time to do (especially when all three of us have real jobs, kids, newborns, animals, etc to deal with). The book is big ... really BIG - 1728 pages, so it can serve many other useful purposes after you are done reading it! :) The book description from the WROX.com ...
This article is a Part 3 of the Interview Questions series. Part 1: BizTalk: Questions for interview without answers Part 2: BizTalk: Interview questions and principles Part 3: WCF: Questions for studying and interviewPart 4: WCF: Questions for studying and interview: DiscoveryPart 5: WCF: Questions for studying and interview: Routing Service Part 6: BizTalk: Advanced Questions Additions (2008-06-18): Debugging: What tools are used for the debugging WCF? Is it possible to log the messages on the ...
Stack walking is second nature to debuggers. But if you had more interest in it than just debugging and either: wanted to know what stack walking is about, or wanted to know how stack walking is implemented, or wanted to know how a custom stack walker can be authored for your application then you might find the article, Authoring a Stack Walker for X86, useful. Its my attempt to help clarify the basics of stack walking and explain key concepts and show how it can be implemented on x86 platform. The ...
I have generally avoided the databound controls provided by the .NET framework. I am referring specifically to controls such as the GridView. Oh don't get me wrong, I use the GridView like I use oxygen. I just don't use an associated DataSource control. Utlimately, therefore, I manually bind controls to data. There are three main reasons I have opted to avoid databound Distributed Applications - Most of the business applications I design incorporate a business layer so it is rare that I bind directly ...
With ASP.NET, we have a bunch of different ways to store data that we want to persist across postbacks: values in session, querystring, viewstate, cookies, etc. One thing that I'm very adamant about is ensuring that these values are enforced with strong typing. Without strong typing, you end up doing a few things: 1. You open yourself up to errors because of typos in the variable names or in duplicate names with differing uses. This one speaks for itself. Because most of the storage methods allow ...
First of two-parts of Cream I've found in my blog-reading: Koen of FirsFloor demonstrates a Slideshow of Picasa WebAlbums, Michael Cameron takes 2D collisions into 3D, Jesse Liberty's first 4 "Did You Know" posts, Bret Ahlstrom discusses the Blend SP1 Update, and Pete Brown in a podcast about Silverlight and the Carbon Calculator application. From SilverlightCream.com: How to integrate Slideshow with the Picasa WebAlbum API Koen of FirstFloor shows how he integrated his very nice Slideshow with Picasa ...
I'm teaching an ASP.NET course for a local university's continuing education department, and its going really well. One thing I introduced yesterday was the idea of paired programming for going through in-class examples and exercises and it worked out very well! It was interesting to see paired programming in action, even if it was a microcosm for what goes on in the real world. The students didn't mind either, and it actually sparked more discussion about how to structure certain code pieces or ...
Ive been developing a few custom adapters for a project recently. Actually one of the adapters was the .net file adapter from the BizTalk SDK samples which we wanted to use and include in our deployment. The aim was as follows: Create the functional code for the adapters Create unit tests to cover as much of the functional code as possible Create a sample BizTalk application to allow demonstration and further testing of the adapters Create BizUnit tests to test the adapters within a BizTalk application ...
Here below is a collection of articles from this blog which seemed to have interested (and benefited) many folks and I thought of sharing the links and the respective topics. Error: allowDefiniton='MachineToAp... - Not configuring a folder as application before using application level settings. http://geekswithblogs.net/r... Dynamically assigning the URL for an Iframe in ASP.NET http://geekswithblogs.net/r... Parser Error: Could ...
Hey Guys! I've got something to share which will help us in our "bugging" life………… Here it goes: Visual Studio 2005: Cool Debugging Tricks http://www.eggheadcafe.com/... Happy Debugging ...
When you want to debug your own written Windows Service, you have to install the service on your local machine and attach the Visual Studio 2005 debugger to the process. There is an easy way to start (and test) the windows service within Visual Studio 2005. 1) Add a public method to your windows service class to invoke the protected OnStart : public void OnStart() { this.OnStart(null); } 2) Add a new class to your windows service project public class Entry { static void Main() { #if DEBUG MediationService ...
I've just finished reading asp.net Ajax in action by Alessandro Gallo, David Barkol and Rama Krishna Vavilala. ISBN-10: 1933988142 My philosophy about javascript can be summed up in one word "yuk!" I keep hoping that the need to learn javascript will pass as the tools catch up and extend the .net dev environment to the browser client. This is happening with much better tools for debugging and deploying javascript in vs 2008. Still i'm a curious person and am embarrased to admit how little javascript ...
I was trying to sovle a sticky problem involving someone else's assemblies but not getting very far -- I needed more information such as line numbers. Usually when you invoke a .NET assembly from BizTalk you need to put it in the GAC and this means you are deprived of the symbols (PDB) which would normally sit beside the assembly in the file system. There are some good posts out there but they seem to relate to .Net 1.0 so they didn't quite work. Here's what you do: You can copy the PDB files directly ...
I found these great links in scott bolg while searching for anyways to speed up Visual Studio 2005 Performance. http://weblogs.asp.net/scot... Tip/Trick: Optimizing ASP.NET 2.0 Web Project Build Performance with Visual Studio 2005 Public Hotfix Patch Available for VS 2005 F5 Debugging Performance Issue with ASP.NET Speed up Visual Studio 2005 Optimize the Launch of Visual Studio 2005 Thanks scottgu ...
Scott Guthrie gave a great keynote this morning. As is turns out VS 2008 is almost complete and we are not getting a copy here at the conference. We will get one mailed to us however after they release it. Which means we will not really be one of the first to get it. :( Visual Studio 2008 - Of course this is going to be able to be used immediately by us due to the fact that you can target .NET Framework 2.0. That means we can just install and continue developing the same applications with AJAX integration ...
For the last few years, I've tried to make more .NET developers aware of the IDisposable interface, the Dispose pattern, and the importance of having at least a basic understanding of how the Garbage Collector works. I have one article on The Code Project and various blog posts (see here, here, here, or here) that talk about these topics. I have also presented an advanced Memory Management presentation at various Code Camps. In the November 2007 issue of MSDN Magazine, Stephen Toub presents a solution ...
It is quite common, that a developer needs to do a few (sometimes time-consuming) steps to navigate to the pages that are required debugging. And if you do some non-trivial change, Edit&Continue doesn't work, and you have to start debugging again. Yes, I know, that small unit tests should cover all the code paths and make debugging redundant. Unfortunately in the real life debugging is sometimes unavoidable. Watin Test Recorder allows to record the navigation steps and save it as a console executable(or ...
I am back to blogging after a vacation..! This time I had an issue with TFS Alert not working properly. You need to make sure that you have done the following setting properly: C:\Program Files\Microsoft Visual Studio 2005 Team Foundation Server\Web Services\Services\Web.config <add key="emailNotificationFromA... value="TFSAdmin@Company.com" /> <add key="smtpServer" value="ExchangeServerName" /> Now you need to reset IIS or recycle the pool that "Services" application is linked with. ...
Recently I worked for the first time with CData sections in XML messages. A CData section in an XML Document starts with <![CDATA[ and ends with ]]> and everything between is ignored by the XML parser. In my scenario I got xml (with some CData sections) from a WebService, transformed it with a map (and did some other things in an orchestration) and sent it to another WebService. The first WS gave me xml with CData but the second WS received none. After some debugging I found out that the xml ...
I received an error that said, "Line 1: Syntax Error." I kept debugging the error, but I didn't think the document definition was causing the error. In the end, I found another developer on the project, had an onmouseover event getting set into a div on via the innerhtml property that included something like onmouseover='somefunction(s... It wasn't quite that simple, but essentially it was too long to find. Unfortunately, the debugging isn't what it should be and the ...
I'm sure most of you are familiar with Reflector. If you're not you should download it immediately and become familiar with it. It is an invaluable tool for looking at .NET assemblies and decompiling them to C#, Visual Basic or even IL. I have used both Reflector and Rotor extensively to investigate how the .NET runtime is actually doing things. I have done this for various reasons, including trying to track down bugs in my code. Why would I need to look at what the runtime is doing to find a bug ...
Check this out at Scotts Blog: source: http://weblogs.asp.net/scot... Releasing the Source Code for the .NET Framework Libraries One of the things my team has been working to enable has been the ability for .NET developers to download and browse the source code of the .NET Framework libraries, and to easily enable debugging support in them. Today I'm excited to announce that we'll be providing this with the .NET 3.5 ...
As you may have heard, Scott Guthrie announced today that they will be releasing the source for the .net framework and that you'll have debugging capabilities inside of VS 2008. You'll actually be able to step into the .net source and see what's going on. This is cool! I'm sure it'll also be a big boost for Mono: "Just how exactly are they writing that code?" How much of the runtime will then be "borrowed" for open source projects? Very good announcement ...
Overview Based on experience, as well an industry acceptance that development teams are construction driven and are always less focused to Software Process. This has been identified and henceforth the inspiration behind the proposed architecture, as a remedy, by keeping build management beyond developer’s domain. Modern configuration environment is getting complex due to rising nature of applications to be distributed whereby they are dependent on their functionality on other applications. Such scenarios ...
improve :my => 'code' I will be posting code examples soon.. But you may not need to wait for my examples to get started as it has really simplified JavaScript development for many. Several lines of code can be written in line most of the time using this library. Here's the link... http://jquery.com/ When you get there, please be sure to check out the many plugins that are available there. (BTW, I have been impressed by Script # from Mr Softie as well... It allows you to write debuggable .NET ...
Jesse Liberty discusses Dependency Properties or is it Attched Properties ? and an older article by Peter Kellner on Debugging in Silverlight 1.1 and Web Services From SilverlightCream.com: Dependency Properties or Attached Properties Jesse Liberty takes a swipe at naming conventions, but in an amongst the text is some good xaml knowledge Integrating Web Services and Silverlight including Debugging Peter Kellner discusses debugging around in a Silverlight 1.1/Web Services application. Stay in the ...
For a long time I have been a big fun of MFC template collections like CArray. The main reason was that they were easy to use and what’s most important quite easy to read in debugger what’s inside them, yet in many places I use mostly STL to take benefit of various collection types and available algorithms. Debugging with STL never was easy, VS 2005 out of the box supports auto expanding of its own STL containers, if you use other implementation than the Microsoft’s one, you have to write your own ...
During my talk on Garbage Collection in .NET at the Jacksonville Code Camp 2007, Joe Healy mentioned that I should take a look at the changes made to the GC in the .NET Framework 3.5 release. (This is based on the Beta 2 release, but it should be pretty stable at this point.) After doing some research using the SSCLI 2.0 code base to look at the GC class as it exists in .NET 2.0 and Reflector to look at it in .NET 3.5, I found the single change that was made. (For those of you wondering why I used ...
Today I had an issue where an application that as a mixture of .NET, VB6 and C++ code needed to be debugged. Since the component that I needed to look at was in the VB 6 portion, I attempted to debug from VB6 only to be met with a variety of bizarre errors. I don't have visibility into the rest of the application, so I continued with the .NET 2005 debugging session, which executed correctly, and noticed that I could set a breakpoint in the VB 6 code when the unmanaged debugging support was turned ...

While debugging a COM Interop error I came across the fact that Binding Failures can now be trapped in the IDE using the BindingFailurse MDA (Managed Debugging Assistant).  Up until today, I'd still been using the FUSLOGVW utility to track down binding failures.

Experiences today have made me realize how important a solid build process is.  I spent 6 hours today trying to get a development environment in a virtual machine to build the source to a component that I needed to help debug.  The actual debugging session has taken less than five minutes and will probably take only about another 30 minutes tomorrow.

This is a great post that anyone who works with WinDbg should check out:

http://geekswithblogs.net/.netonmymind/archive/2006/03/14/72262.aspx

Bookmark it - it will come in handy anytime you're debugging with WinDbg.
I've recently started learning Workflow Foundation in conjunction with Sharepoint Server 2007. One particularly annoying issue I have with it is the development setup needed: its kinda designed to only work on Windows Server 2003. What I mean by this is that some sdks don't install at all on other OSes (like the OfficeServerSDK or the Windows SharePoint Services 3.0 Tools: Visual Studio Extensions), while others do install, they even install the Sharepoint workflow project templates in Visual Studio, ...
The main purpose of writing this is to show how debugging is easy. Orchestration debugging is possible through Health and Activity Tracking (HAT) tool. By the help HAT you can easily debug any active or dehydrated orchestration. Once an instance of an orchestration executes and encounters one of these breakpoints, it will go into a wait state in the BizTalk MessageBox, allowing a developer or administrator to manually step through the orchestration. Run BizTalk application at least one time and then ...
I have quite complicated class and I wanted during debugging/testing to validate that the data in the class is consistent. So I created a method Validate and used it in unit testing class MyComplexClass oClass= MyComplexClass.CreateClass(); Assert.IsTrue(Validate(oCla... But then I understood, that it would be better to call this function in the code to ensure that validation happens in the application, not only in unit testing. So I've added Validate method to the end of my CreateClass() method ...
Visual WebGui is the .net answer for GWT (Google Web Toolkit). But it’s seems more powerful than GWT even though it’s not coming from Microsoft and yet it’s open source. Still I hadn’t got time to put my hands on deeply but you can feel it by just browsing their web site and checking the features and comparing those with GWT. Not like GWT, in Visual WebGui you can use existing windows controls to create your UI. Major advantage of Visual WebGui over GWT is we can deploy Visual WebGui applications ...
I've had a code similar to the following: string sSql = String.Format("Column1 LIKE '%{0}%'", StringValue); fareRows = dataset.Table.Select(sSql); And DataTable.Select method returned me "Cannot perform 'Like' operation on System.Int64 and System.String". System.Data.EvaluateException: Cannot perform 'Like' operation on System.Int64 and System.String. at System.Data.BinaryNode.SetT... op, Type left, Type right) at System.Data.LikeNode.Eval(D... row, DataRowVersion version) at ...
The Problem: If you have been using Vista for a while like me, and you get into situations beyond the capabilities provided in ASP.NET development server (simply like virtual directories), and had to load your development in IIS7, you must have had at least 3 or 4 times of problems with debugging (or simply hitting F5) not working at all. Some of the solutions were creating the website application/v dir yourself not using Visual Studio (This applies to Website model more than Web Application Project ...
Well, I gave my first team presentation today as part of my "Being a Better Developer" goals. Today's topic was "A Refresher Course on Debugging" and you can read the article I wrote for the topic if you follow that link. The article was based on (i.e. copied from) one of the best debugging articles I have ever read. You can read the original and much more in depth article on debugging here (warning, it has a game development focus, but is still applicable to most developers). The presentation itself ...
Debug your code at a Silverlight Lab in Redmond, and new Blend Quickstart on Silverlight.net Come to a Silverlight Lab in Redmond Not busy July 23rd - July 25th and in the Redmond area? Bring your Silverlight project along and bang on the door... they'll even throw in a visit to the company store... free debugging help, low prices at the company store, cool weather ! Silverlight QuickStart Using Microsoft Expression Blend Wow... this is cool... get familiar with the 1.0 QuickStart... then do this ...
This article is a Part 2 of the Interview Questions series. Part 1: BizTalk: Questions for interview without answers Part 2: BizTalk: Interview questions and principles Part 3: WCF: Questions for studying and interviewPart 4: WCF: Questions for studying and interview: DiscoveryPart 5: WCF: Questions for studying and interview: Routing Service Part 6: BizTalk: Advanced Questions This is the questions for a BizTalk developer position during a technical interview.Interview can be very intensive and ...