visual-studio-2008

Refactor "using" statements over an entire codebase?

One of the things I love about Visual Studio 2008 is the ability to refactor and reorganize the "using" statements in source code files (this may have been in 2005 as well, I don't remember). Specifically, I'm talking about how you can have it both reorganize the statements to be alphabetical (though with the core FCL libraries floating...

Using GDI+ Bitmap

Hi I am using GDI+ Bitmap class to convert an IStream to HBITMAP. I have included the gliplus lib file in the Linker inputs and also have the dll in the build path. But using the statement Bitmap bm(lpStream,FALSE); gives me an error C2065: 'Bitmap' : undeclared identifier Can someone please tell me what I am doing wrong here. Tha...

Using IStream to open a file

Hi I am getting the contents of a file in an IStream object. I want to be able to open the IStream contents in a Windows program based on the extension of the file (I know the extension and the mime types) from a dll where I am getting this object. Can someone please tell me how to go about with this. Thanks. ...

VirtualStore not working on Vista x64

I have a little tray application that want's to write to it's own folder under the Program Files directory. I know not an ultimate design and I will fix it, but first I want to understand how this work. Running this on a 32-bit Vista machine it writes the files to the VirtualStore and it works just like it should. But when installing...

VirtualStore not working on Vista x64

I have a little tray application that want's to write to it's own folder under the Program Files directory. I know not an ultimate design and I will fix it, but first I want to understand how this work. Running this on a 32-bit Vista machine it writes the files to the VirtualStore and it works just like it should. But when installing...

What is the "metadata operation failed" VS2008 linker error?

I have a big project that was first created in Borland C++ 6. We're porting the program gradually to VS2008. There are many projects, which all compile to .lib, and I'm trying to build the exe of the test project for a set of projects. After fixing the compiler errors, I got this crazy linker error: *1>av_geos_core_domain.lib(GerTamMo...

Unit testing code that uses PortalSiteMapProvider

I have a web part that uses PortalSiteMapProvider to query the Sharepoint navigation hierarchy, but unit tests written for that code fail, because the code is being run outside the Sharepoint context and thus no site map providers are available. I've identified two alternate ways of solving this dilemma: Because Sharepoint is basicall...

VS 2008 upgrade is changing my dataset designer namespaces

I've been upgrading our solutions from VS 2005 to VS 2008; still targeting the .net 2.0 framework. The conversion wizard is simple and I've never had a conversion failure. The only beef that I've had so far is that I can't immediately compile after the upgrade because VS has changed some of my namespaces causing naming collisions. For e...

Visual Studio Settings Gallery

There use to be a gallery somewhere where people could share their settings for Visual Studio such as fonts, colors, etc. Does anyone know where this is? Follow-up: Anyone have any idea what settings Scott Guthrie is using? Thanks! ...

Anyone know what IDE settings Scott Guthrie is using?

I'm looking to modify my font's and colors to match what Scott Guthrie has. Has he posted this anywhere? ...

How to set DataGridView column properties for automatically generated columns?

I edit data in a DataTable which is bound to a DataGridView. When a new column is created in the DataTable a new column is generated in the view. Ordinarily I would set the view column properties in a DataGridView_ColumnAdded event, however the default for the columns at present is to add a view column with SortMode set to Automatic whi...

Running an installer or checking to see if a program is installed

I have a program that I want to use as an autorun. I want it to be able to do three things. It needs to check to see if a specific program is installed, if it is not, present the user with the option to install it. Second, if the program is installed, present the user with the option of running it and uninstalling it, third, present the ...

event notifications not received as described

Problem: Event notifications (From COM object - Server) are not received as listed in the Sink (class) implementation. One event notification is received (Event_one), however, others are not received accordingly If order is changed - in IDispatch::Invoke, that is: if Event_one is swapped to Event_two then Event_two notification rece...

Using char array properly in vc++

Hi I am trying to convert an IStream to HBITMAP using the GDI+ Bitmap class. The IStream object is being populated by using data from a web service. I am reading the data in parts and appending it to an object to be used later with the Bitmap class. Here is the relevant part of the code char data1[] = ""; int offset = 0; LPTSTR...

Producing 64-bit builds on Windows with free software

Hi, I have a C++ project that I've been developing in Microsoft Visual C++ 2008 Express Edition. It has come to the point that I'd like to port to 64-bit and continue development. What is the best way to do this using free software? My thoughts so far: The Express Edition of MSVC doesn't come with 64-bit compilers, so I can install...

Enable design time support for UserControl in VisualStudio 2008.

I have created usercontrol GridEx:UserControl. On that control I putted GridControl (DevExpress datagrid control). I have created Property DataGrid which return inner datagrid control (previously added) How to enable design support for DataGrid ? I try to put [Designer("DevExpress.XtraGrid.Design.GridControlDesigner, DevExpress.Xtr...

Why are all my Visual Studio test results "Not executed"

When I run my unit tests in my project I am seeing a result "Not executed" for every one. I have restarted my computer so I doubt this is some kind of hung process issue. Google has revealed nothing. Does anyone have any ideas? ...

C# to SQL Server on client's network

I have a client with an established accounting database for which I want to write a report. I am planning to use VS 2008. I have no difficulty doing this for SQL Server running on my own machine but want to know how best to publish a c# program to run on the client's network SQL Server. So there are two main issues: 1.) How to adapt t...

How to unit test F# code in Visual Studio 2008?

I'm new to F# and I intend to create new F# project, and unit test it with F# in Visual Studio 2008, but the Visual Studio 2008 Unit Test Wizard don't have a F# test project option (just have C, C# and VB options). Is it possible to unit test F#? Is it possible to unit test F# with a F# test project? Is it possible to unit test F# with...

VS2008 files and "start debugging"

This may sound like a newbie question - and it is. I'm relatively new to vs, we started using it a few months ago, and I still haven't "mentally" made the change from the command line. So, if you could help me with 2 things: I create a new project (not a solution). He puts the files in some directory. After putting my code inside it, I...