Framework Madness!

And other adventures C# and asp.net …

Posts Tagged ‘Visual Studio 2010

Visual Studio 2010 RC – Problem with parseInt/parseFloat when Using JavaScript Intellisense

leave a comment »

Posted on Connect, but I wanted to see if anyone else had this problem. Here’s the description:

When using a call to ‘parseInt’ or ‘parseFloat’ methods intellisense will become slow, and in the case of jQuery methods not work at all. Commenting out or removing the ‘parseInt’ and/or ‘parseFloat’ call resolves the issue.

Here is the code sample that busts:

Code Snippet
  1. /// <reference path="jquery-1.3.2-vsdoc.js" />
  2.  
  3. $(document).ready(function () {
  4.     //due to parseInt or parseFloat being called intellisense will slow or not work
  5.     //if both are commented out it will work properly, if one if called it slows or breaks
  6.  
  7.     var result1 = parseInt("10", 10);
  8.     var result2 = parseFloat("10");
  9.  
  10.  
  11.     //try using intellisense below this comment – it is very slow
  12.  
  13.  
  14.  
  15. });

If it fails for you too, then follow this link to Connect and confirm. The VS 2010 JavaScript intellisense is great, and we want to help get as many bugs stomped out before the final release.

Written by Lynn Eriksen

February 11, 2010 at 5:56 pm

Visual Studio 2010 Beta 2 – First Impression

leave a comment »

Fast. Seriously, embarrassingly fast. Nice job! 🙂

Written by Lynn Eriksen

October 21, 2009 at 8:59 am

Posted in Uncategorized

Tagged with

Visual Studio 2010 Standard?

with one comment

Just read at Mary-Jo Foley’s  blog that it looks like a lot of the VS 2010 Team Editions are being reworked. But the also mentions a change in SKU’s and that has me wondering if a Visual Studio 2010 Standard edition will be released. I’ve purchased VS 205 and 2008 editions and thought it was a great way to get all the languages without a lot of the Pro edition bells and whistles. And I thought it was worth paying for between $199 – $299.

I would love to hear from Microsoft what is happening to this edition and the future of the express editions.

Written by Lynn Eriksen

October 19, 2009 at 8:22 am

Posted in Uncategorized

Tagged with

Entity Framework ‘Code Only’? If you take the red pill …

with one comment


Updated: Alex James confirms that TPH, TPT and TPC inheritance models will be supported.

 

Well, if you have used the Ado.net Entity Framework so far you know he advantages and the drawbacks. Here are the big drawbacks:

  1. You MUST use XML mapping.
  2. POCO is NOT not straight forward.
  3. No change tracking in the framework.
  4. THE BUILT IN DESIGNER IS SEVERELY LACKING.

Yikes. That cause for a major turn off, or at least a cause for extreme caution. But let me tell you – after working with DataSets for 8 years (about 2/3 years too long) leveraging the Entity Framework with it’s companion Data Services are welcome relief.

Once you get past the designer issues the next big thing is the necessity for XML mapping. The syntax is overly verbose because it’s all encompassing. Not only does it contain DB schema mappings and Class mappings, but mappings between the two as well. If you need to make manual changes things can get messy and confusing in a hurry.

Today they EF team made their first official ‘Code Only’ post to generate initial buzz. The new features look to make XML mapping completely optional and POCO dirt simple. It looks like ‘the plan’ is leveraging the goodness of LINQ to make the meta mappings with code. Here is an excerpt of how a future CTP release (and hopefully the final product) could possible make custom mappings of tables and classes work:

 var builder = new ContextBuilder<MyContext>(); 

 builder[“products”] =  
  from c in builder.OfType<Product>() 
  select new { 
    pcode = p.ID, 
    p.Name, 
    cat = p.Category.ID 
  } 
);

 

The ContextBuilder object serves to apply metadata to a custom ObjectContext that you specify.  Since it is essentially a factory object, once the mappings are applied you can call the ‘create’ method on the builder get the Object Context. For the rest of the mapping details I’ll just lift another excerpt:

 

This snippet (above):

  • Maps Product entities to the ‘prds’ table.
  • Maps Product.ID to a ‘pcode’ column.
  • Maps Product.Name to a ‘Name’ column.

Maps the FK under the Product.Category relationship to the ‘cat’ column.

 

To possibly be that concise and totally refactorable rocks! And they even supply an inheritance example to (table per hierarchy) in the post. The downside – right now it’s vaporware. But this direction is a really welcome change. I hope it gets fully integrated by Beta 2. Almost forgot, they plan to make this work to generate a database as well. Go figure.

Here is the link:

http://blogs.msdn.com/efdesign/archive/2009/06/10/code-only.aspx

Written by Lynn Eriksen

June 10, 2009 at 9:24 pm