visual-studio

How to refactor: split a class into two which communicate via an interface

I am just embarking on my first large-scale refactor, and need to split an (unfortunately large) class into two, which then communicate only via an interface. (My Presenter has turned out to be a Controller, and needs to split GUI logic from App logic). Using C# in VisualStudio 2008 and Resharper, what is the easiest way to achieve this?...

VS.NET "watched" objects and recursive depth

In VS.NET, when you add an item to the watch, why is the base property often (always??) endlessly recursive? ...

Is there a string table resource for Visual C# 2005?

As a developer who spent many years working within Visual C++ 6, I'm used to working with the String Table resource to store unicode strings for localization. Is there a resource within Visual Studio 2005 that provides the same? Are there any third party libraries or tools? ...

New web app project does not recognize the <asp: tag space

Visual Studio 2008 w/Sp1 To reproduce my problem I simply create a new .Net 2.0 web application and add a page with the following markup: <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="WebApplication5._Default" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR...

Keeping track of opensource/freeweare/plugins/etc.

Howdy. I'm a converting mainframe programmer with less than a year of PC programming experience (same company) with VS 2K5. I'm digging the new 'freedom' to try new tools on my PC and have become maybe what you'd call a utility packrat. I have all sorts of open source utilities, freeware utilities, VS plugins/add-ins/snippet collectio...

What would be the most convenient way to connect Visual Studio 2005 (C#) to Oracle8?

I'm looking for best practices for establishing connections between Oracle 8 and Visual Studio 2005 applications. The target would be a Windows Forms application written in C# that hits the database once a second to monitor tables looking for their last inserted record. I'm considering using "Application settings" to store the connection...

Can't import settings in Visual Studio 2008 SP1

I recently baselined my machine and installed VS2008 and I am trying to import my settings file: http://naspinski.net/file.axd?file=naspinski.vssettings I click Tools->Import Settings, select Import selected environment settings and click on Next Next screen I select No, just import new settings, overwrite my current settings and click...

build a string using checkbox

can anybody show me how to build a string using checkbox. what would be the best way to do this. for example i have 4 checkbox's each with its own value (valueA, valueB, valueC, valueD) the thing is i want to display each result in different lines. result if B & C is selected : valueB valueC and how would i display this again if i...

How to set a default configuration in a Visual Studio Solution File?

Hi All, In VS2005 and up, is it possible to specify which configuration should be selected by default? I have several configurations in my solution but one of them should be used in most cases. Hence I'd like to make sure that devs who pull it out of Source Control use the right solution (unless of course they specifically choose anoth...

Can several suites of the same version of Visual Studio be installed Side by Side ?

Hi, I would like to know if I can install say Visual Studio 2008 Pro and Visual Studio 2008 standard on the same machine. I have tried to install the pro (trial edition available on MSDN) after the express, and it seems to require them to be installed in the same directory. Is this specific to the express edition ? The reason why I am ...

Visual studio 2008 - Find in files : lists everything twice

In VS2008, I have a web-site project. When I use find in files and search for a string, the find results window will list every occurence twice. What could be causing this? [EDIT] Below is the screen capture from VS. I was searching for the work CommissionBucketProductID within my website project. Notice that each line is returned twi...

Writing gridview to file does not work with nested for loop

I have this loop, which I am using to get the values of all cells within all rows of a gridview and then write it to a csv file. My loop looks like this: string filename = @"C:\Users\gurdip.sira\Documents\Visual Studio 2008\WebSites\Supressions\APP_DATA\surpressionstest.csv"; StreamWriter sWriter = new StreamWriter(filename); string Str...

.NET VS2005 WinForms: How do i drop a user control onto a form?

i've written a UserControl descendant that is in an assembly dll. How do i drop the control on a form? namespace StackOverflowExample { public partial class MonthViewCalendar : UserControl { ... } } i've added a reference to the assembly under the References node in the Solution Explorer, but no new control has appeare...

Visual Studio solution that just points to a folder and shows all sub-folders and files in the solution explorer?

Is there a way to create a blank solution, or some type of file-based project solution within Visual Studio so that I can point to a root folder, and have all of the sub-folders and files in that root, show up in my solution explorer? I realize I can create a blank solution and then add the individual items manually by add > existing ite...

Help, Visual Studio 2008 filled my profile...

Having recently installed VWDExpress 2008 SP1 on my work machine I find I'm having a problem with the amout of space it uses in: [profile]\Application Data\Microsoft\VWDExpress\9.0 Profile space is restricted by company policy. Does anyone know how to make VS use a different file location? ...

Adding a new project to an existing solution in TFS

I added a project to an existing solution that is currently under source control using TFS, but for some reason I cannot check in the new project. When I view my pending changes, none of the files in the new project show up. None of the files have a plus (for a new file) next to them. What did I do wrong? How do I fix it? It's time ...

Visual Studio (2008) mixed mode project depencies. C-sharp project depends on C++ dll, but C++ dll is not getting re-built

Hi, I have a Visual Studio 2008 solution with two projects in it. A C++ DLL and a Csharp application. The Csharp application uses [DllImport] to access the functions in the DLL, and has a dependency set on the DLL. For some reason, setting the dependency isn't sufficient to cause VS to copy the DLL to the build path of the app. So the...

What are the benefits of maintaining a "clean" list of using directives in C#?

I know VS2008 has the remove and sort function for cleaning up using directives, as does Resharper. Apart from your code being "clean" and removing the problem of referencing namespaces which might not exist in the future, what are the benefits of maintaining a "clean" list of using directives? Less code? Faster compilation times? ...

How can I list the methods of a JavaScript object in VS command window?

When debugging JavaScript in Visual Studio 2008 and I use the ? command in the command window to list a JavaScript object's members I always get that ellipses {...}. Example: >? Page_Validators {...} [0]: {object} [1]: {object} [2]: {object} [3]: {object} [4]: {object} [5]: {object} length: 6 I'm assuming...

Visual Studio 2008 Syntax Coloring Problem

In a VB.NET Web Site, the User Types syntax coloring doesn't work. What are potential causes of this? Note: C# works as expected. Update: It seems to not understand the difference between a "User Type" and an "Identifier." ...