Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with Facebook Sign In with Google Sign In with OpenID

Categories

We have migrated to a new platform! Please note that you will need to reset your password to log in (your credentials are still in-tact though). Please contact lee@programmersheaven.com if you have questions.
Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

C++ in WinXP - Using Visual C++ Express

darklingduckdarklingduck Posts: 8Member
Question, I wrote a program and compiled it. then I brought it to a different PC and not it will not run? Not sure why. Still trying to relearn C++. Any ideas why this is happening?

Robert

Comments

  • LundinLundin Posts: 3,711Member
    You will likely need to include some runtime files. .NET applications in particular requires tons of runtime junk to run, you've probably seen the ".NET framwork yadayada" that Windows always want to update for you.

    I don't know enough of .NET to tell how to set the compiler to include all runtime junk in your .exe, but it should be possible.

  • AsmGuru62AsmGuru62 Posts: 6,519Member
    [color=Blue]From menu bar:
    1. Project -> "name of your project" Properties
    2. In the dialog on the left tree select nodes: "Configuration properties -> C/C++ -> Code generation"
    3. On the right select "Runtime Library" and in that item select something WITHOUT word DLL in it, like "Multi-threaded (/MT)".[/color]
  • darklingduckdarklingduck Posts: 8Member
    Well, I did that and choose Multi-Threaded Debug and got the following error message:

    1>mt.exe : general error c101008a: Failed to save the updated manifest to the file ".DebugBiosVer.exe.embed.manifest". The parameter is incorrect.

    If I change it to just Multi-Threaded I get:

    1>LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library
    1>BiosVer.obj : error LNK2019: unresolved external symbol __CrtDbgReportW referenced in function "public: char const & __thiscall std::_String_const_iterator,class std::allocator >::operator*(void)const " (??D?$_String_const_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBEABDXZ)
    1>libcpmtd.lib(cout.obj) : error LNK2001: unresolved external symbol __CrtDbgReportW
    1>libcpmtd.lib(stdthrow.obj) : error LNK2001: unresolved external symbol __CrtDbgReportW
    1>libcpmtd.lib(xdebug.obj) : error LNK2019: unresolved external symbol __malloc_dbg referenced in function "void * __cdecl operator new(unsigned int,struct std::_DebugHeapTag_t const &,char *,int)" (??2@YAPAXIABU_DebugHeapTag_t@std@@PADH@Z)
    1>libcpmtd.lib(xdebug.obj) : error LNK2019: unresolved external symbol __free_dbg referenced in function "void __cdecl operator delete(void *,struct std::_DebugHeapTag_t const &,char *,int)" (??3@YAXPAXABU_DebugHeapTag_t@std@@PADH@Z)
    1>libcpmtd.lib(_tolower.obj) : error LNK2019: unresolved external symbol __calloc_dbg referenced in function __Getctype
    1>C:Documents and Settings bemis.FAB00400My DocumentsVisual Studio 2008ProjectsBiosVerDebugBiosVer.exe : fatal error LNK1120: 4 unresolved externals
    1>Build log was saved at "file://c:Documents and Settings bemis.FAB00400My DocumentsVisual Studio 2008ProjectsBiosVerBiosVerDebugBuildLog.htm"

    Any Ideas on this one? Thanks for all the help.

    Robert
  • AsmGuru62AsmGuru62 Posts: 6,519Member
    [color=Blue]Did you do "Rebuild Solution" command? Usually, when you change global options - you need to rebuild the whole code - if you have multiple files in a project.[/color]
  • darklingduckdarklingduck Posts: 8Member
    Yeah, I did the Rebuild Solution before and it always failed, I did the Build solution option today and it worked..... Not sure. Will see if it works now. Will let you know, thanks for all the help.

    Robert
Sign In or Register to comment.