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. C / C++ / MFC
  4. How to execute VC++ project(only exe) in a system where VC++ is not installed

How to execute VC++ project(only exe) in a system where VC++ is not installed

Scheduled Pinned Locked Moved C / C++ / MFC
helpc++designtutorial
20 Posts 6 Posters 0 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.
  • S Offline
    S Offline
    shir_k
    wrote on last edited by
    #1

    Hi, I want the project to execute in the system where VC++ is not installed.When i tried to execute my project in 2 systems where there is no VC++, in one system it worked with or without dlls( MFC42D.dll,MFCO42D.dll, MSVCRTD.dll)but in another system first dialog box opens, when i press "ok button" in that dialog box it has to close current dialog box and open next dialog box but the user interface is closing without showing any error. Help me to know why it is happening.Project is working fine in the system where VC++ is loaded. Thanks

    K M C 3 Replies Last reply
    0
    • S shir_k

      Hi, I want the project to execute in the system where VC++ is not installed.When i tried to execute my project in 2 systems where there is no VC++, in one system it worked with or without dlls( MFC42D.dll,MFCO42D.dll, MSVCRTD.dll)but in another system first dialog box opens, when i press "ok button" in that dialog box it has to close current dialog box and open next dialog box but the user interface is closing without showing any error. Help me to know why it is happening.Project is working fine in the system where VC++ is loaded. Thanks

      K Offline
      K Offline
      KarstenK
      wrote on last edited by
      #2

      First step is to make a "Release" build. Your exe is sreaminf for debug dlls.:doh: On VC6 you can make a static link to MFC, so all dependencies are in the bigger exe.

      Greetings from Germany

      S 1 Reply Last reply
      0
      • S shir_k

        Hi, I want the project to execute in the system where VC++ is not installed.When i tried to execute my project in 2 systems where there is no VC++, in one system it worked with or without dlls( MFC42D.dll,MFCO42D.dll, MSVCRTD.dll)but in another system first dialog box opens, when i press "ok button" in that dialog box it has to close current dialog box and open next dialog box but the user interface is closing without showing any error. Help me to know why it is happening.Project is working fine in the system where VC++ is loaded. Thanks

        M Offline
        M Offline
        Matthew Faithfull
        wrote on last edited by
        #3

        The failure may or may not be anything to do with the presence or otherwise of VC++. You can use the depends tools from Microsoft ( shipped with VC++6 Pro ) to determine your .exe's static requirement for Dlls but this is not the problem in your case. You need to add some diagnostic logging/tracing to your application and possibly a crash handler ( There are good examples on CP ) to determine why your app is closing down unexpectedly. It should be able to report the causal error before disappearing even if it's a really nasty fatal problem. The good news is that it is isn't taking down the clients machine on its way out. The bad news is you may need a lot of cooperation from the client to solve the problem. Good luck.

        Nothing is exactly what it seems but everything with seems can be unpicked.

        S 1 Reply Last reply
        0
        • K KarstenK

          First step is to make a "Release" build. Your exe is sreaminf for debug dlls.:doh: On VC6 you can make a static link to MFC, so all dependencies are in the bigger exe.

          Greetings from Germany

          S Offline
          S Offline
          shir_k
          wrote on last edited by
          #4

          I have made release build and also static library then also problem exists

          1 Reply Last reply
          0
          • S shir_k

            Hi, I want the project to execute in the system where VC++ is not installed.When i tried to execute my project in 2 systems where there is no VC++, in one system it worked with or without dlls( MFC42D.dll,MFCO42D.dll, MSVCRTD.dll)but in another system first dialog box opens, when i press "ok button" in that dialog box it has to close current dialog box and open next dialog box but the user interface is closing without showing any error. Help me to know why it is happening.Project is working fine in the system where VC++ is loaded. Thanks

            C Offline
            C Offline
            Cedric Moonen
            wrote on last edited by
            #5

            As your application seems to start correctly (you don't have an error message that is displayed immediately when you launch the app), I suppose that it is not a deployment issue. So, as Matthew stated, it has probably nothing to do with the fact that VC is installed or not. Anyway, it is always better to distribute the release version of your executable. Do you use any ActiveX ? That could be the problem: if you try to use an ActiveX that is not registered, you'll have this kind of problem. If that's not the case, you'll have to dig into more details (like Matthew suggested).


            Cédric Moonen Software developer
            Charting control [v1.2]

            S 1 Reply Last reply
            0
            • M Matthew Faithfull

              The failure may or may not be anything to do with the presence or otherwise of VC++. You can use the depends tools from Microsoft ( shipped with VC++6 Pro ) to determine your .exe's static requirement for Dlls but this is not the problem in your case. You need to add some diagnostic logging/tracing to your application and possibly a crash handler ( There are good examples on CP ) to determine why your app is closing down unexpectedly. It should be able to report the causal error before disappearing even if it's a really nasty fatal problem. The good news is that it is isn't taking down the clients machine on its way out. The bad news is you may need a lot of cooperation from the client to solve the problem. Good luck.

              Nothing is exactly what it seems but everything with seems can be unpicked.

              S Offline
              S Offline
              shir_k
              wrote on last edited by
              #6

              Could u plz tell me the link where i can find Crash handler examples and what does CP means. thanks

              M E T 3 Replies Last reply
              0
              • S shir_k

                Could u plz tell me the link where i can find Crash handler examples and what does CP means. thanks

                M Offline
                M Offline
                Matthew Faithfull
                wrote on last edited by
                #7

                CP is local short hand for Code Project (this site) and you can find lots of useful articles on Crash handling, Error handling, Exception handling, and logging and reporting in the C++/MFC and other sections of the Articles pages on this site. It's probably best if you look yourself for the ones most relevant to what you're doing and the technologies you're familiar with. Failing that a web search for the name 'John Robbins' will get you more information on debugging than you could use ever reasonably use. Enjoy.

                Nothing is exactly what it seems but everything with seems can be unpicked.

                1 Reply Last reply
                0
                • C Cedric Moonen

                  As your application seems to start correctly (you don't have an error message that is displayed immediately when you launch the app), I suppose that it is not a deployment issue. So, as Matthew stated, it has probably nothing to do with the fact that VC is installed or not. Anyway, it is always better to distribute the release version of your executable. Do you use any ActiveX ? That could be the problem: if you try to use an ActiveX that is not registered, you'll have this kind of problem. If that's not the case, you'll have to dig into more details (like Matthew suggested).


                  Cédric Moonen Software developer
                  Charting control [v1.2]

                  S Offline
                  S Offline
                  shir_k
                  wrote on last edited by
                  #8

                  HI, Am using MSComm, this could be the problem. Thanks

                  C 1 Reply Last reply
                  0
                  • S shir_k

                    HI, Am using MSComm, this could be the problem. Thanks

                    C Offline
                    C Offline
                    Cedric Moonen
                    wrote on last edited by
                    #9

                    Try to register it before lauching your application and see what happens.


                    Cédric Moonen Software developer
                    Charting control [v1.2]

                    S 1 Reply Last reply
                    0
                    • C Cedric Moonen

                      Try to register it before lauching your application and see what happens.


                      Cédric Moonen Software developer
                      Charting control [v1.2]

                      S Offline
                      S Offline
                      shir_k
                      wrote on last edited by
                      #10

                      Sorry i didn't get what u r saying

                      C 1 Reply Last reply
                      0
                      • S shir_k

                        Sorry i didn't get what u r saying

                        C Offline
                        C Offline
                        Cedric Moonen
                        wrote on last edited by
                        #11

                        Copy the activeX MSComm32.ocx in the windows\system32 folder (take it from there on your own computer) and use regsvr32 to register it. Click on Start -> run and there type "regsvr32 MSComm32.ocx".


                        Cédric Moonen Software developer
                        Charting control [v1.2]

                        S 1 Reply Last reply
                        0
                        • S shir_k

                          Could u plz tell me the link where i can find Crash handler examples and what does CP means. thanks

                          E Offline
                          E Offline
                          Eytukan
                          wrote on last edited by
                          #12

                          shir_k wrote:

                          what does CP means.

                          sin.


                          Jemmy : Deadline? Pfft, a real programmer eats deadlines for breakfast. :P Mark: I thought real programmers ignored deadlines :sigh: Best wishes to Rexx[^]

                          1 Reply Last reply
                          0
                          • S shir_k

                            Could u plz tell me the link where i can find Crash handler examples and what does CP means. thanks

                            T Offline
                            T Offline
                            toxcct
                            wrote on last edited by
                            #13

                            shir_k wrote:

                            what does CP means

                            it's the abbreviation for the site you're asking on...


                            [VisualCalc][Binary Guide][CommDialogs] | [Forums Guidelines]

                            1 Reply Last reply
                            0
                            • C Cedric Moonen

                              Copy the activeX MSComm32.ocx in the windows\system32 folder (take it from there on your own computer) and use regsvr32 to register it. Click on Start -> run and there type "regsvr32 MSComm32.ocx".


                              Cédric Moonen Software developer
                              Charting control [v1.2]

                              S Offline
                              S Offline
                              shir_k
                              wrote on last edited by
                              #14

                              Hi, I tried above method, it worked for windows 2000 but in XP the problem still exists. What i did is: 1) i copied the file MSComm32.ocx in my system(mine is windows 2000)and placed in XP m/c at location c:\windows\system32 problem didn't get resolved. when i did above step in windows 2000 it worked(i tried in 2 systems) Except mine in all other systems i couldn't register(Click on Start -> run and there type "regsvr32 MSComm32.ocx". ) Thanks

                              C 1 Reply Last reply
                              0
                              • S shir_k

                                Hi, I tried above method, it worked for windows 2000 but in XP the problem still exists. What i did is: 1) i copied the file MSComm32.ocx in my system(mine is windows 2000)and placed in XP m/c at location c:\windows\system32 problem didn't get resolved. when i did above step in windows 2000 it worked(i tried in 2 systems) Except mine in all other systems i couldn't register(Click on Start -> run and there type "regsvr32 MSComm32.ocx". ) Thanks

                                C Offline
                                C Offline
                                Cedric Moonen
                                wrote on last edited by
                                #15

                                shir_k wrote:

                                Except mine in all other systems i couldn't register(Click on Start -> run and there type "regsvr32 MSComm32.ocx". )

                                What was the error message ?


                                Cédric Moonen Software developer
                                Charting control [v1.2]

                                S 1 Reply Last reply
                                0
                                • C Cedric Moonen

                                  shir_k wrote:

                                  Except mine in all other systems i couldn't register(Click on Start -> run and there type "regsvr32 MSComm32.ocx". )

                                  What was the error message ?


                                  Cédric Moonen Software developer
                                  Charting control [v1.2]

                                  S Offline
                                  S Offline
                                  shir_k
                                  wrote on last edited by
                                  #16

                                  Hi, The error message was "Cannot find the file 'regsvr'(or one of its components).Make sure the path and the file name are correct and that all required libraries are available" The systems which got this error doesn't have VC++ installed. I had placed MSCOMM32 at windows\system32\mscomm32.ocx or winnt\system32\mscomm32.ocx Thanks

                                  C 1 Reply Last reply
                                  0
                                  • S shir_k

                                    Hi, The error message was "Cannot find the file 'regsvr'(or one of its components).Make sure the path and the file name are correct and that all required libraries are available" The systems which got this error doesn't have VC++ installed. I had placed MSCOMM32 at windows\system32\mscomm32.ocx or winnt\system32\mscomm32.ocx Thanks

                                    C Offline
                                    C Offline
                                    Cedric Moonen
                                    wrote on last edited by
                                    #17

                                    Type regsvr32 not regsvr.


                                    Cédric Moonen Software developer
                                    Charting control [v1.2]

                                    S 3 Replies Last reply
                                    0
                                    • C Cedric Moonen

                                      Type regsvr32 not regsvr.


                                      Cédric Moonen Software developer
                                      Charting control [v1.2]

                                      S Offline
                                      S Offline
                                      shir_k
                                      wrote on last edited by
                                      #18

                                      Hi, Sorry i was giving the wrong command(regsvr MSComm32.ocx). When i gave regsvr32 MSComm32.ocx it is working fine. Thanks

                                      1 Reply Last reply
                                      0
                                      • C Cedric Moonen

                                        Type regsvr32 not regsvr.


                                        Cédric Moonen Software developer
                                        Charting control [v1.2]

                                        S Offline
                                        S Offline
                                        shir_k
                                        wrote on last edited by
                                        #19

                                        Hi, Its working fine in all the systems, as i had not registered properly it was creating problem. Thanks a lot.

                                        1 Reply Last reply
                                        0
                                        • C Cedric Moonen

                                          Type regsvr32 not regsvr.


                                          Cédric Moonen Software developer
                                          Charting control [v1.2]

                                          S Offline
                                          S Offline
                                          shir_k
                                          wrote on last edited by
                                          #20

                                          Hi, One more Q, in one of the system mscomm32 was existing but created in 1997(when i saw in it properties) when i executed my project it was not working, when i replaced with the mscomm32 which was created in 1998 it started working.Am curious to know why it is so. 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