Monday, January 21, 2008

Microsoft's new agile pace is just killing me.  I'm glad that sp1 will be out some time in the foreseeable future but.  I don't want thing about upgrading to vs 10 in another 18 months. 

C# Debugging Improvements for VS 2008 SP1- Part 1

 

posted by Aaron Fischer on Monday, January 21, 2008 5:18:07 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Thursday, September 06, 2007

Doug Stewart has posted an extensive list of CRL 2.0 bug (hot)fixes.  Its worth a look if your Dot Net 2.0 app is having issues.  Thanks for putting together such a comprehensive list Doug. 

I have seen this issue on a QA server The managed heap becomes corrupted when you run a program that is built by using the Microsoft .NET Framework 2.0 good to see its not my code and that there is a fix for it.

Some of the Hot fix support articles do leave a little something to be desired though I would like to see Microsoft spend the time to detail the cause for each issue so I can better evaluate my need for a given fix.

posted by Aaron Fischer on Thursday, September 06, 2007 6:27:40 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Wednesday, July 25, 2007

I was looking for a way to pass a parameter by reference today.  More specifically the setter.

I found a couple interesting blog posts

http://geekswithblogs.net/akraus1/archive/2006/02/10/69047.aspx

notice the comment by Tedesco.

He offers a nice way to do this via an anonymous delegate.

public delegate void InsertString( System.String param ); public partial class Bird { public void FileToDb( int x) { FillEntityColumn(delegate( System.String value) {tExtra.Text = value; }); } }

So we actual pass the FillEntityColumn method an anonymous delegate which then sets the property.

Now in vb you can write
Public Class Form1

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

        testme(TextBox1.Text)
    End Sub
    Sub testme(ByRef s As String)
        s = "hello"
    End Sub
End Class

which a commenter on http://musingmarc.blogspot.com/2006/04/tale-of-two-implementations.html eluded to.  But in vb you still cannot pass a Property by reference, at least not really.  Take a look what vb generates into il.

Private Sub Button1_Click(ByVal sender As Object, ByVal e As EventArgs)
    Dim VB$t_ref$S0 As TextBox = Me.TextBox1
    Dim VB$t_string$S0 As String = VB$t_ref$S0.Text
    Me.testme((VB$t_string$S0))
    VB$t_ref$S0.Text = VB$t_string$S0
End Sub

 
As you can see vb is writing some code for you which is nice, but we are still not passing the property by ref.
   -Mike has also talked about the want of passing parameters. ( the same misguided comment that vb supports passing parameters by ref)
posted by Aaron Fischer on Wednesday, July 25, 2007 11:27:21 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Friday, June 15, 2007

Scott posted a nice article Tip/Trick: Creating Packaged ASP.NET Setup Programs with VS 2005  for deploying your Visual Studio 2005 project.  While Scott's article is focused on deploying to a customer I have found those scenarios to be beyond what VS offers and requires Install shield.  I do this this post is a handy trick for moving your project from dev to QA to staging maybe even production.

posted by Aaron Fischer on Friday, June 15, 2007 2:02:29 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Friday, May 18, 2007

start by having a solution with two projects.

In the solution exploder window right click the solution and choose add New or existing item.

 

For this how two we will add a new c# class

click add.  Visual studio will create a new suborder under the solution called "Solution Items" Class1.cs will be in this folder.

now select one of your projects and right click select add existing item.  Navigate to your solutions directory and select Class1.cs

click the drop down arrow next to the add button

select add as link

You will now have a shared link to a common solution file/class

repeat for each project you wish to add this file/class to.

posted by Aaron Fischer on Friday, May 18, 2007 12:41:40 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Friday, April 20, 2007

You can find the updated LINQ samples for both VB and C# here

posted by Aaron Fischer on Friday, April 20, 2007 1:47:59 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]

Incase you missed it yesterday Soma announced the release of Orcas Beta 1, it can be downloaded here.

posted by Aaron Fischer on Friday, April 20, 2007 1:43:03 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Tuesday, April 03, 2007

I wanted to take a moment to point out my new favorite DotNet Function.  At VSLive in San Francisco I was introduced to System.IO.Path.Combine( path1, path2) as string.  I no longer have to deal with the logic of adding a trailing or leading slash when combing  file and directory locations.

posted by Aaron Fischer on Tuesday, April 03, 2007 8:27:05 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Monday, March 05, 2007

I have finally found some programing books at my reading level ;)

 

  • C# for Sharp Kids - An ebook on programming with C#
  • VB For Very Bright Kids - An ebook for learning how to programming with Visual Basic
  • Code Rules - A curriculum for learning how to program using Visual Basic. This package includes Teacher materials, Student lessons and quizzes and has been used in schools around the country.
  • CurliQue Studios - A curriculum for learning to build a dynamic web site for a rock band. This one also includes teacher materials. My friend Dave Jacobus blogs about using it with his class and seems to like it.
  • Creating your First Website using HTML - Follow along with this Microsoft DigiGirlz Tech Camp presentation to learn how to use HTML to create your own website!
  • A list of other kid friendly websites and learning resources.

Microsoft's Kid's Corner

posted by Aaron Fischer on Monday, March 05, 2007 6:52:03 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Saturday, February 17, 2007
I found another online code converter this time by SharpDevelop. This will convert between C#, VB,  and Boo.  They also have a web service.

posted by Aaron Fischer on Saturday, February 17, 2007 3:10:09 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Friday, February 16, 2007
Finding a way to use system.io.compression for zip archives
posted by Aaron Fischer on Friday, February 16, 2007 7:27:21 PM (Pacific Standard Time, UTC-08:00)   #    Comments [0]
 Thursday, November 16, 2006
When file position matters
posted by Aaron Fischer on Thursday, November 16, 2006 11:13:49 AM (Pacific Standard Time, UTC-08:00)   #    Comments [0]