Compiling in Visual Studio 2008

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • arielro
    New Member
    • Feb 2008
    • 3

    Compiling in Visual Studio 2008

    Hello all!
    I have a C# application that uses 5 dlls and each time I make a modification to the script and test it(ctrl+F5) the application compiles successfully but doesn't seem to apply the changes I made. So I have to run the project one more time to actually see the modifications happen. Is there any way to make the enviroment(VS 2008) apply the changes exactly after I make them in code.
    Am I missing something?

    Cheers,
    Ariel
  • debasisdas
    Recognized Expert Expert
    • Dec 2006
    • 8119

    #2
    How is that possible.

    You are making changes to DLL or to the application ?

    Comment

    • r035198x
      MVP
      • Sep 2006
      • 13225

      #3
      Originally posted by arielro
      Hello all!
      I have a C# application that uses 5 dlls and each time I make a modification to the script and test it(ctrl+F5) the application compiles successfully but doesn't seem to apply the changes I made. So I have to run the project one more time to actually see the modifications happen. Is there any way to make the enviroment(VS 2008) apply the changes exactly after I make them in code.
      Am I missing something?

      Cheers,
      Ariel
      Are you talking about the "Build Automatically" feature that is available in IDEs like Eclipse and Netbeans? That is turned on by default in VS 2008(Express).

      Comment

      • dzenanz
        New Member
        • Feb 2008
        • 45

        #4
        Menu Project->Project Dependencies...

        You can define there what is dependent upon what, so VS can infer correct build order (you can see it on the other tab, make sure all dlls are built before app). This eliminates need to compile twice before code changes apply.

        HTH, Dženan

        Comment

        • arielro
          New Member
          • Feb 2008
          • 3

          #5
          It doesn't matter if i make changes to the application itself or dlls. I just have to re-run the Start Without Debugging feature(Ctrl+F5 ) to make them happen.

          Comment

          • Plater
            Recognized Expert Expert
            • Apr 2007
            • 7872

            #6
            You have to run your application, close it, then run it again?
            That really sounds like build order problems.

            Comment

            • brockweaver
              New Member
              • Jun 2008
              • 3

              #7
              You might have the dependent dll's referenced as File references instead of Project references. If you did Browse... to add the reference, that's why you're not seeing your changes.

              Project references monitor the source assembly (dll) and update the local copy of it as needed (aka when recompiled).

              File references copy the assembly into the local path only when VS loads. That's why restarting VS.NET works, but does not work on a normal recompile.

              Just drop all your references to dll's in your solution, then re-add them as Project references and you should be set.

              Comment

              Working...