Tag: linkedin

  • Debug NUnit Tests With Visual Studio

    1. Set a break point in a unit test 2. Open NUnit 3. In Visual Studio, go the tools Menu and choose Attach to Process (or Ctrl-Alt-P) 4. Choose nunit out of the list 5. Run tests. Make sure you run the test where your breakpoint is if you don’t run all tests.

  • Javascript Scoping

    If you understand what’s going on when this runs, then you understand javascript scoping. var x = 5; alert(x); function foo(){alert(x);var x = 10;alert(x);} foo(); alert(x);

  • JScript.Net and C# Interaction

    // lib.cs: using System; namespace Library {   public class TestLib {     public static void speak(){        Console.WriteLine(“Hello From CSharp Dll”);     }   } } // hello.js import System; import Library; var a = {name:’JScript Object in Exe’}; a.foo = function (){   Console.WriteLine(‘Hello From ‘ + this.name); }; a.foo(); TestLib.speak(); Compiling: 1. […]

  • Javascript Objects and Hashes

    Employee = { New: function(fname,lname,em) { return { first: fname, last: lname, email: em, displayName: function() { return this.last + ‘, ‘ + this.first }, sig: function() { return this.displayName() + ‘ ‘ + this.email } } } } var tim = Employee.New(‘Tim’, ‘Hoolihan’,’tim@hoolihan.net’) tim.sig()

  • Help With Path Issues

    First, here’s a good way to see what you have available in code… <form id=”form1″ runat=”server”> <div> <% For Each key As String In Request.ServerVariables.AllKeys%> <p><%= key %>: <%=Request.ServerVariables(key)%></p> <% Next %> </div> </form> But in general all you need to do is read the following: http://weblogs.asp.net/scottgu/archive/2006/12/19/tip-trick-how-to-run-a-root-site-with-the-local-web-server-using-vs-2005-sp1.aspx