Posts Tagged ‘visual-studio-2008’

Excellent, now I can detect Visual Studio design time anywhere in my code. (Make sure to read the comments, they provide a valuable correction.)

I came across interesting issue with one of our controls. I needed a different behavior during design-time and run-time. I was sure that .NET Framework has a nice solution for me, but I found out this is not the case.There is a DesignMode property but according to several sources it doesn’t always work as expected. There seems to be more that one way to solve the issue. I decided to useSystem.Diagnostics.Process.GetCurrentProcess.ProcessNameand check if it equals string “devenv”. If it does, the instance is running inside Visual Studio, which means it’s design-time for our control. For my problem this simple solution worked as a charm.

via Detecting Design-time in C#.


Read Full Post »

This looks fun, I’d like a chance to give it a go sometime.

Today, the team released Microsoft Visual Studio 2008 AJAX Profiling Extensions – a new power tool to measure the performance of the portions of web applications that execute JavaScript inside the web browser.

VS2008 AJAX Profiling Extensions

Read Full Post »

Like most applications, a database plays a critical role in what I’m working on. Fortunately, two higher-end versions of Visual Studio are supposed to provide a Microsoft security blanket for developing a database, managing and tracking changes to a database, and deploying those changes. (Among other things)


Unfortunately, Microsoft left the security blanket for getting these pieces all working on a dirty bus seat in downtown Seattle.

First, you need the Enterprise or Developer edition of Sql Server installed. If you upgrade from a previously installed version and change the instance name be prepared for an rather unhelpful error message.

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces,  Error Locating Server/Instance Specified)

You’ll receive this error message if you don’t have the correct instance name specified.

Database projects require a connection to a local instance of Microsoft SQL Server 2005 for design-time validation. To perform this operation, you must open the Tools menu, click Options and specify an instance of SQL Server 2005 that is running and to which you can connect in the Database Tools, Design-time Validation Database property page. When that is corrected, you must then refresh or reload the database project.

Or if you don’t have the correct version of Sql Server installed.

As it turns out, the error messages were a bit misleading. The actual problem was that I had the wrong edition of SQL Server installed on this machine. I had SQL Server Standard Edition installed, but to create a Database Project from within Visual Studio you must have either the Developer or Enterprise editions of SQL Server 2008 installed.

As with all software make sure to install the latest patches.

Although the name “GDR”, which stands for “General Redistribution Release”, implies otherwise, this really is a complete new release, based on a new architecture. We have taken the architectural changes from the Rosario project (Visual Studio Team System 2010) and rolled them forward in time. Rolling forward these changes help us align the GDR release with the upcoming Visual Studio Team System 2010 release and provide numerous new features and extensibility points in this release. If you would compare the GDR release with the “Visual Studio 2005 Team Edition for Database Professionals” or “Visual Studio Team System 2008 Database Edition” you will agree this is a completely new product!

And oh wait the latest patch just happens to remove that Sql Server requirement! Did I mention that you MUST use Sql Server 2005 if you don’t install this patch? And just ignore the fact that the references below to “SQL Express or SQL Server” should in fact be “SQL Server 2005 Developer or SQL Server 2005 Enterprise”.

Database Edition no longer requires a Design Database. Therefore, it is no longer necessary to install an instance of SQL Express or SQL Server prior to using Database Edition.

After all that fun the Validation feature seems to be broken but hopefully I’ll figure that out soon and everything will be downhill from here on out.

Yeah right. 🙂

Read Full Post »

A reference to the master.dbschema (or similar, see below!) is necessary for database projects in Visual Studio that reference system objects. Here’s how to add those objects without slowing everything down.

In the March edition of MSDN we provided an overview of Server Projects and how to reference the master.dbschema file to resolve references to system objects. If you have a project that references the master.dbschema file, you may have noticed it takes a while to establish this reference. You may have also noticed the project may not load or deploy as quickly as it did before referencing the master.dbschema file. This is because when referencing the master.dbschema file you are adding all the system objects found in a typical SQL Server instance to your database model in Visual Studio. The number of system objects defined in the master.dbschema file greatly outnumbers the user created objects for many database projects. If you have multiple projects referencing the master.dbschema file this can be compounded as each projects reference to the master.dbschema has its own copy of the database model in memory.

via VSTS: DB Best Practices : Right sizing the master.dbschema file for better design time performance.

Read Full Post »