Convert particular VS 2008 solution and projects to VS 2005

Hello,

do you know how to convert this project to VS 2005? http://www.codeproject.com/KB/miscctrl/cpam.aspx

thanks
LVL 6
xRalfAsked:
Who is Participating?
 
Éric MoreauSenior .Net ConsultantCommented:
Create a new project in VS2005 and add all classes/forms/... to this new project. Unless it is using VS2008 features it should work.
0
 
rambovnCommented:
0
 
xRalfAuthor Commented:
Thanks rambovn,

do you know how to convert the project I gave in my question?
0
Cloud Class® Course: Microsoft Exchange Server

The MCTS: Microsoft Exchange Server 2010 certification validates your skills in supporting the maintenance and administration of the Exchange servers in an enterprise environment. Learn everything you need to know with this course.

 
rambovnCommented:
"Before installing the newest version of IDE I successfully used this approach when getting VS2008 projects
from our users (in truth I only changed two numbers, 10 to 9 and 8 to 5, in the solution file and it worked for me)."
0
 
xRalfAuthor Commented:
to emoreau: There are many files to add manually, it is easy to make a mistake here.

to rambovn: I changed the number 10 to 9 in the CPAM.sln file. Number 8 isn't there. And it didn't help.
0
 
Éric MoreauSenior .Net ConsultantCommented:
>>to emoreau: There are many files to add manually, it is easy to make a mistake here.

But at least it will work.
0
 
rambovnCommented:
you can try this: http://msmvps.com/blogs/jon_skeet/archive/2007/11/20/vs2005-and-vs2008-co-existence.aspx

I can not test it for you, because i use 2008
0
 
xRalfAuthor Commented:
I'm looking for something quick without playing with files and settings too much... Is there something like this? It is necessary everytime you need to convert VS 2008 to VS 2005 to do many editing and manual settings?
0
 
rambovnCommented:
AFAIK, there is no tool to automatize these process.
One reason for no such tool is there are new features in 2008 that 2005 do not has
0
 
xRalfAuthor Commented:
to moreau

I tried to do it manually, but the problem occured with System.Linq. It's probably VS 2008 feature.
0
 
Éric MoreauSenior .Net ConsultantCommented:
LINQ is definitely a .Net Framework 3.5 feature and it cannot be used in VS 2005.
0
 
xRalfAuthor Commented:
I did it again. I create new Windows application from existing code, completed missing references. I deleted one assembly info and it was compiled without errors. But the application ended with exception

System.Reflection.TargetInvocationException was unhandled
  Message="Exception has been thrown by the target of an invocation."
  Source="mscorlib"
  StackTrace:
       at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
       at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
       at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
       at System.Delegate.DynamicInvokeImpl(Object[] args)
       at System.Windows.Forms.Control.InvokeMarshaledCallbackDo(ThreadMethodEntry tme)
       at System.Windows.Forms.Control.InvokeMarshaledCallbackHelper(Object obj)
       at System.Threading.ExecutionContext.runTryCode(Object userData)
       at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData)
       at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Windows.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry tme)
       at System.Windows.Forms.Control.InvokeMarshaledCallbacks()
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
       at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
       at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData)
       at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
       at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
       at System.Windows.Forms.Application.Run(Form mainForm)
       at Tester2.Program.Main() in C:\Documents and Settings\CPAM\CPAM\Program.cs:line 18
       at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)
       at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
       at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
       at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Threading.ThreadHelper.ThreadStart()
0
 
xRalfAuthor Commented:
That's interesting: I created the project first as console application and System.Linq was there (so I only commented the lines). I think this wasn't used. But I had to create the project as Windows application and there were no troubles with Linq.
0
 
Éric MoreauSenior .Net ConsultantCommented:
There is surely something wrong in your code. You seem to use a COM object. Is it properly registered.

Have you tried the code in VS2008? Is it working correctly?
0
 
xRalfAuthor Commented:
I don't have VS 2008. But because is possible to trace I will accept your answers.
0
 
Éric MoreauSenior .Net ConsultantCommented:
>>I don't have VS 2008

you could download the Express edition or a Trial.
0
 
xRalfAuthor Commented:
thanks for info
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.