Welcome to the .NET Developers Blog
This is an aggregated blog of non-Microsoft .NET developers
I don't have a problem with Microsoft blogs and love reading them, but I feel that there is also need for a non-Microsoft blog site to see what the .NET community is buzzing about.
Another reason why I created this aggregator site is because I don't want blogs to be restricted to any specific domain. So, regardless of where you are hosting your blog, feel free to add your blog to this list.
The idea is to have a centralized website that aggregates all those .NET, C#, VB.NET, ASP.NET, Whidbey, Longhorn, WinFX blogs into one. Email me for any suggestions and feedback.
- Minh T. Nguyen
|
Visual Studio .NET Tips and Tricks
|
|
|
Outlook 2007... Architect Edition?
Andrea Saltarello - 5/12/2008 1:18 AM PST
|
|
Credevo di aver installato "Office 2007 Ultimate", ma probabilmente ha ragione Roby: MS mi ha fornito una build custom. Il motivo? Beh, stavo scrivendo a una mail e il correttore ortografico di Outlook ha appena "corretto" *domani mattina* in *domain mattina* <g>
|
Two LINQ to SQL Myths
K. Scott allen - 5/11/2008 9:57 PM PST
|
|
LINQ to SQL requires you to start with a database schema.
Not true – you can start with code and create mappings later. In fact, you can write plain-old CLR object like this:
class Movie
{
public int ID { get; set; }
public string Title { get; set; }
public DateTime ReleaseDate { get; set; }
}
… and later either create a mapping file (full of XML like <Table> and <Column>), or decorate the class with mapping attributes (like [Table] and [Column]). You can even use the mapping to create a fresh database schema via the CreateDatabase method of the DataContext class.
LINQ to SQL requires your classes to implement INotifyPropertyChanged and use EntitySet<T> for any associated collections.
Not true, although foregoing either does come with a price. INotifyPropertyChanged allows LINQ to SQL to track changes on your objects. If you don't implement this interface LINQ to SQL can still discover changes for update scenarios, but will take snapshots of all objects, which isn't free. Likewise, EntitySet provides deferred loading and association management for one-to-one and one-to-many relationships between entities. You can build this yourself, but with EntitySet being built on top of IList<T>, you'll probably be recreating the same wheel. There is nothing about EntitySet<T> that ties the class to LINQ to SQL (other than living inside the System.Data.Linq namespace).
LINQ to SQL has limitations and it's a v1 product, but don't think of LINQ to SQL as strictly a drag and drop technology.
|
Bloody rain on race day
Chris Hammond - 5/11/2008 9:37 PM PST
|
|
So I guess I didn't need any practice going into the Atlanta Pro Solo next weekend (aka Doublecross). It was raining and windy this morning when I left the house, but I had every intention of running the event out at Gateway Raceway.
I get out there and I see that there are no cones on the lot for a course, and it looks like people are leaving. Sure enough, the damn event was cancelled. I hung around the lot for 20-30 minutes to chat with the stragglers who were still there, and those who were showing up.
|
GET HOST NAME & IP IN ORACLE 10G
Marlon Ribunal - 5/11/2008 5:16 PM PST
|
|
Use the Oracle 10g utility ”UTL_INADDR” to get the Local Host Name and IP of the machine your Oracle 10g is running on. You can do this by executing the following commands:
SQL> SET serveroutput on
SQL> BEGIN
2 DBMS_OUTPUT.PUT_LINE(UTL_INADDR.GET_HOST_NAME); — Local machine/host name
3 DBMS_OUTPUT.PUT_LINE(UTL_INADDR.GET_HOST_ADDRESS); — IP address of host
4 END;
5 /
DEVSTATION
192.168.1.3
PL/SQL procedure successfully completed.
Just a note.
-Marlon RIbunal
[...]
|
try/catch/finally and resource protection: mistakes to avoid
Christophe Menet - 5/11/2008 12:06 PM PST
|
I had to take over a project last week, an ASP.NET application. I found a lot of mistakes regarding resources protection and the use of try/catch/finally block. For instance, I found that:
SqlConnection con = new SqlConnection() try { con.Open(); // Some code here } catch (Exception ex) { throw ex; } finally { if (con != null) con.close(); }
During a normal processing, if the code inside the try block works, everything is fine. No problem.
Now, imagine:
1- // Some code here raises an exception.
First, the execution goes to the catch block. This one does nothing than re-throwing the same exception (by the way, I advice you to read this post about rethrowing exceptions and preserving the full call stack trace, explaining how you will loose some important information like the stack trace of the exception). In this case, the block is useless.
Then, the execution goes to the finally block. The connection exists (con != null) and is closed. But the test is wrong… we should check if the connection is not null, and not if the connection is opened! The test is quite different, even if it works in this case.
2- con.Open() fails and raises an exception
The execution goes in the catch block (still useless) and then in the finally block. In this case, the connection exists (con != null) and is closed. But the con.Close() call will throw an exception, because the previous con.Open() didn’t work. The current exception will be lost (ie. “con.Open() failed”) and will be replaced by another one (ie. “con.Close() failed”). You loose some information about the problem you had.
This is now a better way to write your code:
SqlConnection con = new SqlConnection() con.Open(); try { // Some code here } finally { con.Close(); }
In this situation:
1- If con.Open() raises an exception
The execution goes out immediately, with the “con.Open() failed” exception.
2- If // Some code here raises an exception
The execution goes directly to the finally block, closes the connection (that was previously opened) and then goes out of the function with the appropriate exception.
This method works fine, and is also much more readable!
Talking about connections, you can also use in a better way the using statement! For instance:
using (SqlConnection con = new SqlConnection()) { // Some code here }
The generated MSIL code will be translated as a try/finally block (as shown in this post about the using statement), just like our previous sample. This one is just easier to read and to write, and you will not forget to close the connection.
|
EntitySpaces 2008 - LINQ to SQL in Next Beta (Part 2)
Mike Griffin - 5/11/2008 8:51 AM PST
|
|
Oh, I almost forgot the most important thing. And that is using LINQ to SQL to populate
data directly into your EntitySpaces collections, oh man this is hot !!
DataContext context = new DataContext("User ID=sa;Initial Catalog=Northwind;Data
Source=localhost;");
var linqQuery = context.GetTable<Employees>().Where(s
=> s.LastName == "Griffin")
.OrderBy(s => s.LastName);
EmployeesCollection coll = new EmployeesCollection();
coll.Load(context, linqQuery);
foreach (Employees emp in coll)
{
Console.WriteLine(emp.FirstName);
}
Notice that we pass the context and the linqQuery directly into our EntitySpaces EmployeeCollection's
Load() method, the rest is the same as usual, awesome !!
From mobile devices to large scale enterprise solutions in need of serious transaction
support, EntitySpaces can meet your needs. Whether you’re writing an ASP.NET application
with medium trust requirements, a Mono application, or a Windows.Forms application,
the EntitySpaces architecture is there for you. EntitySpaces is provider independent,
which means that you can run the same binary code against any of the supported databases.
EntitySpaces is available in both C# and VB.NET. EntitySpaces uses no reflection,
no XML files, and sports a tiny foot print of less than 200k. Pound for pound, EntitySpaces
is one tough, dependable .NET architecture.
The EntitySpaces Team
--
EntitySpaces LLC
Persistence Layer and Business Objects for Microsoft .NET
http://www.entityspaces.net
|
LINQ in Multi-tier Applications
Paschal L - 5/11/2008 7:03 AM PST
|
If you had the chance to work with LINQ, the latest Object Relational Mapping tool (ORM) added to the .NET 3.5 platform, then you understand how LINQ maps your database structure into several classes in your application. It creates for each table an entity...(read more)
|
Passing parameters in .Net Remoting
Michael Freidgeim - 5/11/2008 5:08 AM PST
|
|
It is well known, that in .Net value type parameters are passed by value, and reference type parameters are passed by reference.
I thought(even after a year working with application that extensively uses Remoting) that .Net Remoting calls do the same. But I was wrong!
Recently I found that a method with custom class parameter doesn't have one of the properties updated after return, even if it is certainly updated inside the method.
I looked for a few reference articles.
Object passing. All objects created remotely are returned by reference and have to derive from MarshalByRefObject. Objects passed as parameters to a remote method call can be forwarded by value or by reference. The default behavior is pass by value provided the object in question is marked by the custom attribute [Serializable]. Additionally, the object could implement the ISerializable interface, which provides flexibility in how the object should be serialized and deserialized. Objects that are not marshal by reference or marshal by value are not remotable.
Because parameter ForwardMe does not inherit from MarshalByRefObject, it is passed by value to the server.
And finally, article Copying, Cloning, and Marshalling in .NET clarified it:
By default, all objects in .NET (both value- and reference-types) are marshalled by value when sent across the "wire" to a remote AppDomain.To override this default MBV behavior, one can simply derive one's class from System.MarshalByRefObject .
So the Rules for passing parameters in .Net Remoting are the following.
1. Parameter should have attribute [Serializable] or derive from MarshalByRefObject.
(It would be unusual for a class to be both marked with the serializable attribute and extend MarshalByRefObject.)
2. If parameter is serializable, it is passed by value. Changes inside remote methods do not return to the client.
3. If parameter derive from MarshalByRefObject , it is passed by reference.
4. I am not sure, what happens If you specify modifier ref for serializable parameter. I hope that it is also passed by reference, but not sure.
I did not have a chance to read, what are WCF rules for passing parameters. 
|
From Earth Day to Eugene
Paul Litwin - 5/10/2008 6:31 PM PST
|
|
My marathon career started when I was 14 while a freshman at Archbishop Molloy High School in NYC. I had run cross-country and indoor track and there was a bit of gap before outdoor track was to start. My brother Bill and some of his friends decided they were going to run in the Earth Day Marathon that April in 1973. Bill, 2 years older than me, was always up for a challenge and I said what the heck. Up to that point, I think the longest I had ever run was maybe 9 miles but heck 26 didn't sound too bad. I finished the race that windy, snowy April day in just under 4 hours, swearing I would never run another marathon again. I ran Earth Day 3 more times in high school, running 3:24 as a sophmore, setting a PR of 3:09 in 1975 when I was in my junior, and DNF'ing because of a heel injury in my senior year. Just googled "Earth Day Marathon" and found this reference to the first Earth Day race I ran in 1973 in a June 26, 2007 article in Long Island Newsday by John Hanc (http://www.hamptonsmarathon.com/Stories/Documents/Newsday%20Article%206.26.07.doc): ... staged 34 years ago, in March, 1973, at the old Roosevelt Raceway in Westbury. It was called the Earth Day Marathon. … The Earth Day race was a spin-off of a race staged in prior years in Central Park (and before that in the Bronx) by the New York Road Runners. Held in the very early days of what would become known as the 1970s running boom, the race evinced the spirit of that time, and not only in its celebration of the then-nascent environmental movement. The Earth Day Marathon, a loop course around the raceway (note: the author is wrong with this bit of history; the race started and finished at the raceway but then moved to 3 loops around Eisenhower Park), was tough and so were the competitors, as suggested by the words of founding race director Paul Fetscher: "Whatever kind of day it is, the weather will be a challenge," he told reporters, "and veteran die-hard runners will not shrink away from it, but fight it." He was right. In conditions that the winner, Larry Frederick, would describe as "horrid," biting March winds reached 30 miles per hour, while temperatures sank to the freezing mark. Yet 400 runners battled through it, displaying determination if not great fashion sense. … The marathon world, however, seems to be getting more and more crowded. When the Earth Day Marathon began, it was probably one of only 10 26.2-mile road races in the entire country...
Fast forward 28 years to 2003. After many years of off again, on again running, I finally got serious about doing another marathon, having joined a local running group (ChuckIt) run by Chuck Barlett in 2002. Unfortunately, my first adult effort at Capitol City in Olympia blew up on me. I was cruising in 3:22 pace through mile 17 when it all started to unravel; suffice it to say I hit the wall (I prefer that metaphor to the more trendy "bonk") hard but still managed to walk away (literally for several miles) with a 3:37. In 2004, I ran a bit more conservatively but still managed a visit with the wall and came in somewhere between 3:50 and 4:00. Two bad experiences in a row. Damn. Right after that I started having severe pain in the ball of my left foot right below the pinky toe. This continued to bother me for some time so I laid of of running for a long while after getting an MRI, various other tests, therapies, orthotics, and treatment from various podiatrists, doctors, physical therapists, and massage therapists. I continued to lay off of running, eventually taking up biking. At one point late in 2005 I started running again, but was quickly sidelined with a similar injury in my right foot after a couple of months. At this point, I decided to learn to swim and took up training for sprint triathlons in early 2006, running two in the summer of 2006 and three in the summer of 2007. (I can't say enough good things about Mary Meyer Life Fitness in teaching me to swim and getting me in great triathlon shape.) So after a successful triathlon summer and remaining injury free, I decided to set my signts on the Seattle Half Marathon. I started training again with ChuckIt. Training went pretty well and I ended up running a respectable 1:37 on the grueling Seattle Half-Marathon course. The weather was great in 2007 but I have to say that the course is a killer. There's just way too many hills but I ran well, managing to hold a pretty steady 7:30 pace pretty much the whole race. At that point, Peter (my younger brother) said he was doing the Eugene marathon in May. I felt good coming off of Seattle, so I decided to start training for Eugene. Training over the next four months went well. I did my second 20 miler 5 weeks prior to the race and was planning to do another one 3 weeks out but at 4 weeks before the race my left foot started hurting again after a 13 miler. Same pain at same location as before. My physiscal therapist, Bruk at Real Rehab (highly recommended) fashioned a quick orthotic to try and take some pressure off the foot and I took a full week off, substituting hard workouts on the eliptical trainer for running. Meanwhile, my confidence took a dive; still I managed to stay smart and combined running with eliptical work so that I didn't lose too much fitness for the race. After all, this happened during the last month which was always the month of the taper. I took the Friday before the race off and Suzanne, Anna, Matthew, and I drove down to Eugene--technically I did all the driving but you get the point. Saturday, we went to the expo and I got my number, went to Eugene's version of the farmer's market and generally had a relaxing day. We hooked up with Peter (my brother), Gerry (his friend), and Cassandra (Gerry's friend) for dinner at the Oregon Electric Station. I had vegetable lasagna and lots of bread but no beer to cap off a sucessful week of carbo loading. After dinner, Gerry, Cassandra, Peter, and I visited Hayward field (the exulted center of the running universe where Steve Prefontaine, et al trained and raced) at the U of O. When we were done checking out the course and discussing the finer points of running and having to go potty during the race they dropped me off at my hotel. Before going to sleep, I mapped out 3 points on the course (at miles 7, 17, and the finish) with approximate times for Suzanne and the kids to meet me. I went to bed and after a half hour or so of tossing and turning managed to get a good 6 hours of sleep. More details on the race to come in a separate post...
|
IIS 7 resource guide post by Mike Volodarsky
Steve Schofield - 5/10/2008 5:15 PM PST
|
Lead author Mike Volodarsky posted info regarding IIS 7 Resource Guide book. http://mvolo.com/blogs/serverside/archive/2008/05/01/The-IIS-7.0-Resource-Kit-Book.aspx It was great being associated with such talented bunch of authors. Hope you enjoy the...(read more)
|
Ruby In Steel Personal - FREE with PC Pro
Huw Collingbourne - 5/10/2008 10:18 AM PST
|
This month's edition of the UK's PC Pro magazine (it says July on the cover but it's already available in the middle of May, I promise you) has a free copy of Ruby In Steel on the cover DVD! Ruby In Steel Personal (2008) is available exclusively with PC Pro. It contains everything you need to get up and running with Ruby and Rails including a free Ruby-language copy of Visual Studio 2008. The Personal Edition has all the same editing and project management features as our (...)
|
Speaking Dates Sam Gentile Spring 2008
Sam Gentile - 5/10/2008 7:32 AM PST
|
|
Repeating.................... mostly for myself....
| March 17, 2008 |
Lehigh Valley .NET |
| March 27, 2008 |
Northern Delaware .Net User Group |
| March 31-April 1, 2008 |
Microsoft Real World SOA for Government, Reston MTC, Reston VA |
| April 2, 2008 |
NuCon 08 with Microsoft, SetFocus |
| April 7, 2008 |
Microsoft Mid Atlantic Partner Briefing |
| April 13-19, 2008 |
Microsoft MVP Summit, Redmond WA |
| April 22-25, 2008 |
Microsoft Health & Life Sciences Developer and Solutions Conference 2008, |
| May 10, 2008 |
TechBash 2008 |
| May 17, 2008 |
Philly Code Camp |
| May 20, 2008 |
Central Pennsylvania .NET Users Group |
| June 6, 2008 |
Capital Area .NET Users Group |

|
“SQL Server and .NET Training and Career Development” by Douglas Reilly
Marlon Ribunal - 5/10/2008 4:55 AM PST
|
|
[This 3-part series was written by Douglas Reilly who died early 2007. The articles were written in February to June of 2006.]
This is the Part I of the series: The Value of Conferences
And here is the Part II: The Benefit of Forum
Finally, Part III: Importance of Books and the Constant Change
Author profile: Douglas Reilly
The late Douglas Reilly was the owner of Access Microsystems Inc., a
small software development company specializing in ASP.NET and mobile
development, often using Microsoft SQL Server as a database. He died
early in 2007 and is greatly missed by the SQL Server community as one
of the industry’s personalities.
[Courtesy of http://www.simple-talk.com]
Please do read these articles with much solemnity. And I broke into tears when I read this. Here's a picture of Doug and his wife, Jean
-Marlon Ribunal

|
“SQL Server and .NET Training and Career Development” by Douglas Reilly
DevPinoy.Org - 5/10/2008 3:18 AM PST
|
|
[This 3-part series was written by Douglas Reilly who died early 2007. The articles were written in February to June of 2006.]
This is the Part I of the series: The Value of Conferences
And here is the Part II: The Benefit of Forum
Finally, Part III: Importance of Books and the Constant Change
Author profile: Douglas Reilly
The late Douglas Reilly was the owner of Access Microsystems Inc., a
small software development company specializing in ASP.NET and mobile
development, often using Microsoft SQL Server as a database. He died
early in 2007 and is greatly missed by the SQL Server community as one
of the industry’s personalities.
[Courtesy of http://www.simple-talk.com]
Please do read these articles with much solemnity. And I broke into tears when I read this. Here's a picture of Doug and his wife, Jean
-Marlon Ribunal

|
want to be a .NET star **{*}**?
Hannes Preishuber - 5/9/2008 8:28 AM PST
|
|
you can not sing - you are running slow- you are not rich - you haven't invented the wheel ? perhaps you a good coder? we are looking for our German and Austrian sub's for upcoming .NET star's. Several MVP's, authors and speakers come from us. If you want attend the star way, take a look at our web site. 
|
ALT.NET South Africa
Forest Blog - 5/9/2008 4:54 AM PST
|
|
The altdotnet.org.za site is now online. The purpose of this site is to bring together South African developers who are following the international ALT.NET discussions. The idea is not to replace or duplicate the international community but to create a local space where we can collaborate to discuss the things that affect us in a Southern African (and African) context. Please feel free to dive in, add content and start some conversations!
|
[OT] La verita' sul numero degli hacker rumeni
Adrian Florea - 5/9/2008 4:41 AM PST
|
|
Spesso nei media italiani (ma anche nei media rumeni) appaiono notizie sugli hacker rumeni come i piu' cattivi o i piu' numerosi malfattori informatici al mondo a tal punto che quasi ho finito per crederci... E' per questo che trovare le cifre reali, prese dal "2007 Internet Crime Report" (il PDF del link ha 7.42 MB), mi ha sorpreso molto: la Romania conta solo all'1,5% seguita subito dall'Italia coll'1,3% (?!), mentre gli Stati Uniti hanno il primato col 63,2% ed UK col 15,3% del totale dei malfattori ("perpetrators") informatici (p. 11 del PDF).
Fonte: questo post in rumeno di Valy Greavu
|
|