.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

CLR UDA debug

Posted By:      Posted Date: October 10, 2010    Points: 0   Category :Sql Server
I found on Check here this code for skewness and kurtosis:
using System;
using System.Data;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using Microsoft.SqlServer.Server;
   IsInvariantToDuplicates = false, 
   IsInvariantToNulls = true,       
   IsInvariantToOrder = true,     
   IsNullIfEmpty = false)]            
public struct Skew
       private double rx;         // running sum of current values (x)
       private double rx2;        // running sum of squared current values (x^2)
       private double r2x;        // running sum of doubled current values (2x)
       private double rx3;        // running sum of current values raised to power 3 (x^3)
       private double r3x2;       // running sum of tripled squared current values (3x^2)
       private double r3x;        // running sum of tripled current values (3x)
       private Int64 rn;          // running count of rows
       public void Init()
              rx = 0;
              rx2 = 0;
              r2x = 0;
              rx3 = 0;
              r3x2 = 0;
              r3x = 0;
              rn = 0;
       public void Accumulate(SqlDouble inpVal)

View Complete Post

More Related Resource Links

Debug implementation of URLrewriter.net



After some googling and help from the forum, I have integrated the the URLrewrting.net in my project. There are no error when I build the project, but the URL rewriting does not work. I am able to figure ot where the problem is. Is there a way to debug this. The code is as below:

 Web.config file

<?xml version="1.0"?>
    Note: As an alternative to hand editing this file you can use the 
    web admin tool to configure settings for your application. Use
    the Website->Asp.Net Configuration option in Visual Studio.
    A full list of settings and comments can be found in 
    machine.config.comments usually located in 
		<sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
			<sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
				<section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.W

Debug Leaky Apps: Identify And Prevent Memory Leaks In Managed Code


When is the .NET Garbage Collector unable to reclaim memory? The answer might surprise you. Stay tuned.

James Kovacs

MSDN Magazine January 2007

Debugging Tool: Build a Logging and Event Viewing Library to Help Debug Your .NET Framework-based Ap


Building a basic, reusable application framework can make development quicker and easier. This allows you to focus more on the problems at hand and less on the repetitive tasks involved in building any application. In this article, the author presents a framework that provides facilities to access the registry and an extensible framework for logging messages to a console window or the Event Viewer. This reusable framework can be included as a library in your projects, allowing you to display an enhanced, color-coded message log and dynamically change logging levels.

Daryn Kiely

MSDN Magazine May 2003

Debug: Detect and Plug GDI Leaks in Your Code with Two Powerful Tools for Windows XP


In a previous article, the author devised a simple method to detect Graphical Device Interface (GDI) objects that are not properly released by Win32-based applications on Windows 9x platforms. Because some newer versions of Windows require a slightly different approach to GDI leaks, the author has updated his techniques for those operating systems. He builds and explains two tools designed to detect and eradicate GDI leaks in applications running on Windows XP, Windows 2000, and Windows NT.

Christophe Nasarre

MSDN Magazine January 2003

Editor's Note: Elevating Test and Debug


Programming is fun. It's one of the world's great jobs, pure mental exercise with a golden payoff at the end. There's nothing like the feeling of accomplishment when that program you wrote is working, looks good, and is ready to ship.

MSDN Magazine January 2003



I'm following , and, trying to complete a working project which displays information from an XML file, however, VS 2008, is displaying the following errors, which I can't really understand:

  • Error 1 Invalid expression term ',' c:\inetpub\wwwroot\TestWebSite\Default.aspx 1 1 http://localhost/TestWebSite/
  • Error 2 ) expected c:\inetpub\wwwroot\TestWebSite\Default.aspx 1 1 http://localhost/TestWebSite/
  • Error 3 ; expected c:\inetpub\wwwroot\TestWebSite\Default.aspx 1 1 http://localhost/TestWebSite/
  • Error 4 Invalid expression term ')' c:\inetpub\wwwroot\TestWebSite\Default.aspx 1 1 http://localhost/TestWebSite

Source code here

error 500 in IIS, but work in debug



I have a website that is built in .Net framework 4. I have set up the site in IIS 7 on a win 7 and set the applicationpool to .Net 4. But the weird thing is that I cannot access the site if I go through IIS, I can only access the site if I debug the site from within VS 2010. 

Anyone got any ideas of where I should start to look?

how to debug assemblies in GAC?

hello all, i have custom dlls that are installed to GAC. Now i need to debug them using Vs.net 2008. How do i do the same ?   Regards durga  

How can I debug Windows Service using Visual Studio?

How can I debug Windows Service using Visual Studio? I wrote in Visual Studio 2008 Command Promt: installutil -i c:\projects\MyProject\bin\debug\win.exe I did Start to may service ,but every time that I want to debug service I get: Cannot start service from the command line or a debugger. A Windows Service must first be installed (using installutil.exe) and then started with the ServerExplorer, Windows Services Administrative tool or the NET START command.   What am I doing wrong?   Thanks, Raya        

How to display breakpoint and debug visual cues with custom activity designer based on WorkflowViewE

Hi,   I am developing custom activity designers based on "WorkflowViewElement" instead of "ActivityDesigner" in my xaml. It allows me to have greater control of the look and feel of the designer. However I noticed that with this approach, the breakpoint visual cue (Dark red solid circle that appears on the left side of the designer when you set breakpoint on the designer) is not visible. It works fine when you write your designed based on "ActivityDesigner". The same behavior happens to the debug visual cue when you debugging the WF. It appears as bright yellow rectangle surrounding the activity designer if you are based on "ActivityDesigner", but it is not available when your designer is based on"WorkflowViewElement". Any help is highly appreciated. Li

Unable to debug asp.net web service

Hi,I recently formatted my machine and installed iis and then VS 2008.I created a sample  asp.net web service and just tried to debug it.That time it throwed this error:"Unable to start debugging on the web server.  <html><head><title>Server Application Error </title></head><body><h1>Server Application Error</h1>The server has encountered an error while loading an application during the processing of your request.  Please refer to the event log for more detail information.  Please contect the server administrator for assistence.</body></html>"Please tell me what am I missing or what all settings needs to be done in iis.

How to debug a complex function?

Hi everybody, I got a few complex functions written by my colleague to review. These functions calculate cost of goods using one of the methods (passed as a parameter) (FIFO, RWAC, LAST cost). I've been looking at these functions or running some queries based on these functions, but I'm yet not sure I understand them fully and their logic. What is the best approach for me to test / understand these functions? Thanks in advance.Premature optimization is the root of all evil in programming. (c) by Donald Knuth Naomi Nosonovsky, Sr. Programmer-Analyst My blog

How to figure out if package runs in debug mode

Hi, I would like to know whether there is a possiblity to dynamically determine at runtime if a script is runing in debug mode or is being executed via SQL Server Agent? My goal is to prompt the user with some information e.g. initial catalog ensuring the package is being ran in the correct environment (development/production). However, as SQL Server Agent does not support MessageBoxes I would like to write some alternative code in this case. Thanks in advance!

Not Able to debug while application is running.

 Hi I am working with a Visual studio 2005 (2.0 frame work) with a windows application When I am Running the application in Debug mode and if I do some code change it is giving the following exception.   "C:\\XXX\bin\Debug\Scheduling.dll] Invalid Typeref token.     Could not load type "System.ComponentModel.Component" from assembly "Version=, CultureCould not load type "System.ComponentModel.Component" from assembly "Common, Version=, Culture=neutral, PublicKeyToken=null".=neutral, PublicKeyToken=null". 1:00:34 PM "

How to debug feature activation by PowerShell

Hello, I got a bunch of wsp files with double the number features from my visual studio 2010 solution. So now I'm using PowerShell to add and install the wsp files to my server and to activate the features for the target site. In Visual Studio 2010 rightlicking and hitting "deploy" works perfectly fine while the PowerShellscript fails with a NullReferenceException. Is there a way to locate the error? I've tried to debug the PowerShell process but when VS2010 opens up to debug the process I get an empty window without any code. I'm using a Windows Server 2008 R2, SharePoint 2010 RTM and Visual Studio 2010 RTM.
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend