Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Windows API
  4. Code Compiled on Vista won't run on XP

Code Compiled on Vista won't run on XP

Scheduled Pinned Locked Moved Windows API
csharpc++visual-studioquestion
10 Posts 6 Posters 10 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    preludeoflight
    wrote on last edited by
    #1

    I've recently upgraded one of my production machines to Vista, and all has gone quite well, with one little hitch. I'm coding in/compiling with Visual Studio 2005, and C++ that I write/build on my Vista machine runs fine there, but when I try to use the executable on XP, I'm presented with this: <edit: link removed> Any Idea as to what may have caused this misconfiguration? Sorry if this is the wrong place to ask, I'm somewhat new to this community. Thanks!

    M P 2 Replies Last reply
    0
    • P preludeoflight

      I've recently upgraded one of my production machines to Vista, and all has gone quite well, with one little hitch. I'm coding in/compiling with Visual Studio 2005, and C++ that I write/build on my Vista machine runs fine there, but when I try to use the executable on XP, I'm presented with this: <edit: link removed> Any Idea as to what may have caused this misconfiguration? Sorry if this is the wrong place to ask, I'm somewhat new to this community. Thanks!

      M Offline
      M Offline
      Michael Dunn
      wrote on last edited by
      #2

      You need to run the C++ runtime installer on the other machine (the OS isn't a factor here, it's missing DLLs). Go do %VSDIR%\sdk\v2.0\BootStrapper\packages and you'll see dirs named vcredist_*. Go into the dir that matches the CPU of the other machine, and grab the EXE from that dir. Copy it to the other machine and run it. And yes, that is a horrible error message. :sigh:

      --Mike-- Visual C++ MVP :cool: LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ Ford, what's this fish doing in my ear?

      A B 2 Replies Last reply
      0
      • M Michael Dunn

        You need to run the C++ runtime installer on the other machine (the OS isn't a factor here, it's missing DLLs). Go do %VSDIR%\sdk\v2.0\BootStrapper\packages and you'll see dirs named vcredist_*. Go into the dir that matches the CPU of the other machine, and grab the EXE from that dir. Copy it to the other machine and run it. And yes, that is a horrible error message. :sigh:

        --Mike-- Visual C++ MVP :cool: LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ Ford, what's this fish doing in my ear?

        A Offline
        A Offline
        Anton Afanasyev
        wrote on last edited by
        #3

        Michael Dunn wrote:

        the OS isn't a factor here, it's missing DLLs

        True in this case, but I think I remember back when Win2000 was the latest, and you compiled under 2000, you couldn't run it in 98. I may be wrong though, might've been VB...


        :badger:

        M 1 Reply Last reply
        0
        • A Anton Afanasyev

          Michael Dunn wrote:

          the OS isn't a factor here, it's missing DLLs

          True in this case, but I think I remember back when Win2000 was the latest, and you compiled under 2000, you couldn't run it in 98. I may be wrong though, might've been VB...


          :badger:

          M Offline
          M Offline
          Michael Dunn
          wrote on last edited by
          #4

          The OS you compile on has never affected the OSes that the EXE will run on. If I build an app on Vista and use the ANSI Win32 APIs, the EXE will run all the way down to Win 95. It's always about getting the right versions of the CRT (and MFC if you use it) DLLs on the target systems.

          --Mike-- Visual C++ MVP :cool: LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ Ford, what's this fish doing in my ear?

          P 1 Reply Last reply
          0
          • M Michael Dunn

            The OS you compile on has never affected the OSes that the EXE will run on. If I build an app on Vista and use the ANSI Win32 APIs, the EXE will run all the way down to Win 95. It's always about getting the right versions of the CRT (and MFC if you use it) DLLs on the target systems.

            --Mike-- Visual C++ MVP :cool: LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ Ford, what's this fish doing in my ear?

            P Offline
            P Offline
            preludeoflight
            wrote on last edited by
            #5

            Right. That's what I assumed. Thing being, this little 'project2' I did was just a simple little app including things like iostream, conio.h, fstream, exception, and a few others, nothing fancy. I suppose I should just figure out what files are missing that I need. Thanks All!

            S 1 Reply Last reply
            0
            • P preludeoflight

              Right. That's what I assumed. Thing being, this little 'project2' I did was just a simple little app including things like iostream, conio.h, fstream, exception, and a few others, nothing fancy. I suppose I should just figure out what files are missing that I need. Thanks All!

              S Offline
              S Offline
              Shin Ra
              wrote on last edited by
              #6

              works fine on Windows XP Pro Corp SP2

              1 Reply Last reply
              0
              • M Michael Dunn

                You need to run the C++ runtime installer on the other machine (the OS isn't a factor here, it's missing DLLs). Go do %VSDIR%\sdk\v2.0\BootStrapper\packages and you'll see dirs named vcredist_*. Go into the dir that matches the CPU of the other machine, and grab the EXE from that dir. Copy it to the other machine and run it. And yes, that is a horrible error message. :sigh:

                --Mike-- Visual C++ MVP :cool: LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ Ford, what's this fish doing in my ear?

                B Offline
                B Offline
                BJ Nash
                wrote on last edited by
                #7

                Does running this put additional dlls on the target machine or does it overwrite existing ones? I don't want to break any existing programs that run just fine. Thanks!

                M 1 Reply Last reply
                0
                • B BJ Nash

                  Does running this put additional dlls on the target machine or does it overwrite existing ones? I don't want to break any existing programs that run just fine. Thanks!

                  M Offline
                  M Offline
                  Michael Dunn
                  wrote on last edited by
                  #8

                  It will install the new DLLs in the side-by-side directory, it won't overwrite older versions.

                  --Mike-- Visual C++ MVP :cool: LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ Ford, what's this fish doing in my ear?

                  1 Reply Last reply
                  0
                  • P preludeoflight

                    I've recently upgraded one of my production machines to Vista, and all has gone quite well, with one little hitch. I'm coding in/compiling with Visual Studio 2005, and C++ that I write/build on my Vista machine runs fine there, but when I try to use the executable on XP, I'm presented with this: <edit: link removed> Any Idea as to what may have caused this misconfiguration? Sorry if this is the wrong place to ask, I'm somewhat new to this community. Thanks!

                    P Offline
                    P Offline
                    Paresh Chitte
                    wrote on last edited by
                    #9

                    Please check manifest file embedded in your executable. Regards, Paresh.

                    P 1 Reply Last reply
                    0
                    • P Paresh Chitte

                      Please check manifest file embedded in your executable. Regards, Paresh.

                      P Offline
                      P Offline
                      preludeoflight
                      wrote on last edited by
                      #10

                      I'm a bit of a new programmer, and I'm not quite sure how to go about this :) Could you link me to a guide or the sort, my Google skills are failing me this morning. Thanks ============ Edit: I should play around a bit before asking a silly question. I got the manifest, but it's not much help to me; is VC80.CRT referring to the dll it's needing? Further, is there a way to change the dependency to use an earlier version, such as the one that ships with XP or 2000? Here's the Manifest if anyone's interested: Edit 2: I've done some reading up on how the manifest works, so as to not require direct linking of common Visual C++ files... but I don't think I want to have someone install the VC++ runtime files, when I only need say, one for example. Is it possible to tell Visual Studio to include files like MSVCR80.DLL directly in my exe, so I can have it as a standalone executable? Thanks!

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups