programm will not start

This is a discussion on programm will not start within the C++ Programming forums, part of the General Programming Boards category; Hi I have a problem, my programm does not run on any windows pc (I mean win 2000 and up). ...

  1. #1
    Registered User
    Join Date
    Feb 2006
    Posts
    71

    programm will not start

    Hi

    I have a problem, my programm does not run on any windows pc (I mean win 2000 and up). Sometimes it does and sometimes nothing happens. I think it must be something with dlls. But I don't know which dlls my programm needs. Is there a possibility to find that out. And when I know them what to do next? Just copy the dlls in the programm folder of my exe?

  2. #2
    Devil's Advocate SlyMaelstrom's Avatar
    Join Date
    May 2004
    Location
    Out of scope
    Posts
    4,069
    If your missing a DLL, normally a prompt will come up saying "Missing XXXXX.dll"

    I can't imagine that's the problem... especially if it's "your program." Are you loading the DLL dynamically? If so are you checking to see if it loaded properly?

    So, can you be more descriptive as to when it opens and when it doesn't, any errors you get when it doesn't... and if you did write the code, consider posting some of it.
    Last edited by SlyMaelstrom; 07-02-2006 at 07:10 AM.
    Sent from my iPadŽ

  3. #3
    Registered User
    Join Date
    Feb 2006
    Posts
    71
    Quote Originally Posted by SlyMaelstrom
    If your missing a DLL, normally a prompt will come up saying "Missing XXXXX.dll"

    I can't imagine that's the problem... especially if it's "your program." Are you loading the DLL dynamically? If so are you checking to see if it loaded properly?

    So, can you be more descriptive as to when it opens and when it doesn't, any errors you get when it doesn't... and if you did write the code, consider posting some of it.
    I have this

    Code:
    #pragma comment (lib,"ws2_32")
    
    #pragma comment (lib,"cryptlib")
    #pragma comment (lib,"libeay32")
    #pragma comment (lib,"ssleay32")
    in my programm code. But all of them except ws2_32 get implemented in my programm, so my programm run without these dlls, I tested it.
    So there is I think not the problem. When the programm doesn't start there is no error message (my programm is a dll I don't know if dlls post no error message). I looked into the compiled exe with a hex editor and found some dll names and looked them up on a computer on which my programm doesn't run, but the dlls
    are there, could it be that that computer have the wrong version of the dlls? The names of the dlls I found are the following KERNEL32.DLL ADVAPI32.dll USER32.dll WS2_32.dll
    Problem is I can't just overwride them with that dlls of my computer. So what to do?

  4. #4
    Registered User
    Join Date
    Aug 2003
    Posts
    1,205
    Show us some code. We can only guess but show us the minimal amount of code to reproduce this and we can help you.
    STL Util a small headers-only library with various utility functions. Mainly for fun but feedback is welcome.

  5. #5
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,592
    > Sometimes it does and sometimes nothing happens
    I would expect a missing DLL to report consistent error messages.
    This sounds more like bugs in your program.

    Post some actual error messages rather than "it doesn't work".
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  6. #6
    Registered User
    Join Date
    Feb 2006
    Posts
    71
    Quote Originally Posted by Salem
    > Sometimes it does and sometimes nothing happens
    I would expect a missing DLL to report consistent error messages.
    This sounds more like bugs in your program.

    Post some actual error messages rather than "it doesn't work".
    Hmm how to post error messages when there are no. And what of the code to you want to see. The programm has 10 .cpp files and 8 .h files the total code is more than 60 Din A 4 printed pages.

    P.S. the programm is compiled with the compiler of MS Visual Studio 2003.
    Last edited by keeper; 07-02-2006 at 10:01 AM.

  7. #7
    Devil's Advocate SlyMaelstrom's Avatar
    Join Date
    May 2004
    Location
    Out of scope
    Posts
    4,069
    Well if you have the time and knowledge to write all that, then surely you have enough debugging knowledge to find the error yourself or at least find someone else in person to help you debug. Besides telling you that it's most likely not a problem with missing DLLs we really can't do much about debugging that much code over the internet.
    Sent from my iPadŽ

  8. #8
    Registered User
    Join Date
    Feb 2006
    Posts
    71
    Quote Originally Posted by SlyMaelstrom
    Well if you have the time and knowledge to write all that, then surely you have enough debugging knowledge to find the error yourself or at least find someone else in person to help you debug. Besides telling you that it's most likely not a problem with missing DLLs we really can't do much about debugging that much code over the internet.

    OK thank you.

  9. #9
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,046
    I have a problem, my programm does not run [...] sometimes it does and sometimes nothing happens.
    What is "nothing happens"? The DOS box flashes? You get a segmentation fault? Or you don't see anything at all?
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  10. #10
    Registered User
    Join Date
    Aug 2003
    Posts
    1,205
    My bet would be that this problem could be resolved by doing any of these things.
    STL Util a small headers-only library with various utility functions. Mainly for fun but feedback is welcome.

  11. #11
    Devil's Advocate SlyMaelstrom's Avatar
    Join Date
    May 2004
    Location
    Out of scope
    Posts
    4,069
    Quote Originally Posted by keeper
    The programm has 10 .cpp files and 8 .h files the total code is more than 60 Din A 4 printed pages.
    Quote Originally Posted by Shakti
    My bet would be that this problem could be resolved by doing any of these things.
    I'd... seriously doubt that Shakti.
    Sent from my iPadŽ

  12. #12
    Registered User
    Join Date
    Feb 2006
    Posts
    71
    Quote Originally Posted by dwks
    What is "nothing happens"? The DOS box flashes? You get a segmentation fault? Or you don't see anything at all?
    The programm for what my dll is written is an nt service, so no when it does not run I see nothing.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Adventures in labyrinth generation.
    By guesst in forum Game Programming
    Replies: 8
    Last Post: 10-12-2008, 01:30 PM
  2. C++ gui for windows where to start
    By prixone in forum Windows Programming
    Replies: 2
    Last Post: 12-16-2006, 10:48 PM
  3. GNOME Desktop won't start (Mandriva)
    By psychopath in forum Tech Board
    Replies: 10
    Last Post: 07-19-2006, 01:21 PM
  4. printing with a c programm
    By -11Reaper11- in forum C++ Programming
    Replies: 3
    Last Post: 04-30-2006, 10:31 AM
  5. Next Question...
    By Azmeos in forum C++ Programming
    Replies: 3
    Last Post: 06-06-2003, 02:40 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21