Program crash - no rhyme or reason

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • John Grogan

    Program crash - no rhyme or reason

    I am experiencing problems with one Visual Basic project. It is prone
    to crashing - in the VB IDE and also when running a fully compiled
    executable. When it crashes in the IDE, then VB terminates too with no
    error message. When the standalone EXE crashes there are no error
    messages either. The project is reasonably big - 60 forms, 20
    modules, 7 class modules, and it references a couple of custom DLLs
    too.

    I've tried running Dr Watson and it reports nothing. Similarly the
    Event Viewer has no errors either. When running in Debug mode, the
    crash terminates VB. The crashes are unpredictable - don't always
    happen at the same point.

    Any suggestions? I'm running VB 6.0 Service Pack 5 on Windows XP
    Professional.
  • J French

    #2
    Re: Program crash - no rhyme or reason

    On 20 Apr 2004 02:27:48 -0700, johntgrogan@hot mail.com (John Grogan)
    wrote:
    [color=blue]
    >I am experiencing problems with one Visual Basic project. It is prone
    >to crashing - in the VB IDE and also when running a fully compiled
    >executable. When it crashes in the IDE, then VB terminates too with no
    >error message. When the standalone EXE crashes there are no error
    >messages either. The project is reasonably big - 60 forms, 20
    >modules, 7 class modules, and it references a couple of custom DLLs
    >too.
    >
    >I've tried running Dr Watson and it reports nothing. Similarly the
    >Event Viewer has no errors either. When running in Debug mode, the
    >crash terminates VB. The crashes are unpredictable - don't always
    >happen at the same point.
    >
    >Any suggestions? I'm running VB 6.0 Service Pack 5 on Windows XP
    >Professional .[/color]

    When did the problem start ?

    Comment

    • Randy Birch

      #3
      Re: Program crash - no rhyme or reason

      March 25th. <g>


      (Don't ask the question if you don't want to hear the answer) :-)

      --

      Randy


      "J French" <erewhon@nowher e.com> wrote in message
      news:408505d4.1 [email protected] click.com...


      : When did the problem start ?

      Comment

      • J French

        #4
        Re: Program crash - no rhyme or reason

        On Wed, 21 Apr 2004 03:58:43 GMT, "Randy Birch"
        <rgb_removethis @mvps.org> wrote:
        [color=blue]
        >March 25th. <g>
        >
        >
        >(Don't ask the question if you don't want to hear the answer) :-)
        >[/color]

        Heh,

        I bet he did something to his system

        Ah well, start stropping Occam's razor

        Comment

        • John Grogan

          #5
          Re: Program crash - no rhyme or reason

          erewhon@nowhere .com (J French) wrote in message news:<40867098. [email protected] tclick.com>...[color=blue]
          > On Wed, 21 Apr 2004 03:58:43 GMT, "Randy Birch"
          > <rgb_removethis @mvps.org> wrote:
          >[color=green]
          > >March 25th. <g>
          > >
          > >
          > >(Don't ask the question if you don't want to hear the answer) :-)
          > >[/color]
          >
          > Heh,
          >
          > I bet he did something to his system
          >
          > Ah well, start stropping Occam's razor[/color]

          ?

          After scouring the archives here I've set the project to compile to
          "P-code" and it is slightly more stable, but still crashes
          occasionally. Think it started to happen after I added custom DLLs.

          Comment

          • J French

            #6
            Re: Program crash - no rhyme or reason

            On 22 Apr 2004 04:51:04 -0700, johntgrogan@hot mail.com (John Grogan)
            wrote:

            <snip>
            [color=blue][color=green]
            >> I bet he did something to his system
            >>
            >> Ah well, start stropping Occam's razor[/color]
            >
            >?[/color]

            That means cutting out bits of the code until you isolate the problem.
            [color=blue]
            >
            >After scouring the archives here I've set the project to compile to
            >"P-code" and it is slightly more stable, but still crashes
            >occasionally . Think it started to happen after I added custom DLLs.[/color]

            'Real' DLLs or AX things ?

            If it is 'real' DLLs then you might have faulty declarations, or the
            DLLs themselves might be buggy.

            Comment

            • John Grogan

              #7
              Re: Program crash - no rhyme or reason

              erewhon@nowhere .com (J French) wrote in message news:<4088bae6. 173175501@news. btclick.com>...[color=blue]
              > On 22 Apr 2004 04:51:04 -0700, johntgrogan@hot mail.com (John Grogan)
              > wrote:
              >
              > <snip>
              >[color=green][color=darkred]
              > >> I bet he did something to his system
              > >>
              > >> Ah well, start stropping Occam's razor[/color]
              > >
              > >?[/color]
              >
              > That means cutting out bits of the code until you isolate the problem.[/color]

              Thanks - it was actually the March 25th reference that I didn't
              understand though ;)
              [color=blue]
              >[color=green]
              > >
              > >After scouring the archives here I've set the project to compile to
              > >"P-code" and it is slightly more stable, but still crashes
              > >occasionally . Think it started to happen after I added custom DLLs.[/color]
              >
              > 'Real' DLLs or AX things ?
              >
              > If it is 'real' DLLs then you might have faulty declarations, or the
              > DLLs themselves might be buggy.[/color]

              ActiveX DLLs - I picked up some sample code that creates a wrapper
              round a third-party Mapping ActiveX that's a major part of my project.
              The sample project that I downloaded works fine, but the wrapper DLL
              seems to be causing problems in my own project.

              Comment

              • Randy Birch

                #8
                Re: Program crash - no rhyme or reason

                : Thanks - it was actually the March 25th reference that I didn't
                : understand though ;)


                JG: I am experiencing problems with one Visual Basic project....

                JF: When did the problem start ?

                RB: March 25th. <g>

                Nothing more than a (humorous) example of answering the question asked.
                Y'know, the type of answer a systems op could expect to get from an
                end-user.

                --

                Randy


                Comment

                • J French

                  #9
                  Re: Program crash - no rhyme or reason

                  On 23 Apr 2004 07:58:22 -0700, johntgrogan@hot mail.com (John Grogan)
                  wrote:
                  [color=blue]
                  >erewhon@nowher e.com (J French) wrote in message news:<4088bae6. 173175501@news. btclick.com>...[color=green]
                  >> On 22 Apr 2004 04:51:04 -0700, johntgrogan@hot mail.com (John Grogan)
                  >> wrote:
                  >>
                  >> <snip>
                  >>[color=darkred]
                  >> >> I bet he did something to his system
                  >> >>
                  >> >> Ah well, start stropping Occam's razor
                  >> >
                  >> >?[/color]
                  >>
                  >> That means cutting out bits of the code until you isolate the problem.[/color]
                  >
                  >Thanks - it was actually the March 25th reference that I didn't
                  >understand though ;)[/color]

                  That was Randy - not me
                  [color=blue][color=green]
                  >>[color=darkred]
                  >> >
                  >> >After scouring the archives here I've set the project to compile to
                  >> >"P-code" and it is slightly more stable, but still crashes
                  >> >occasionally . Think it started to happen after I added custom DLLs.[/color]
                  >>
                  >> 'Real' DLLs or AX things ?
                  >>
                  >> If it is 'real' DLLs then you might have faulty declarations, or the
                  >> DLLs themselves might be buggy.[/color]
                  >
                  >ActiveX DLLs - I picked up some sample code that creates a wrapper
                  >round a third-party Mapping ActiveX that's a major part of my project.
                  > The sample project that I downloaded works fine, but the wrapper DLL
                  >seems to be causing problems in my own project.[/color]

                  Ok, for a start put : Option Explicit: DefObj A-Z
                  at the top of every Form, BAS module Class etc
                  - it may make something jump out of the woodwork

                  If that does not solve the problem (and it probably will not, but it
                  is good practise) then examine /all/ API Calls very carefully.
                  A faulty definition can give just such problems

                  Stick in Error Handling and see whether anything jumps out

                  I prefer On Error Resume Next, and to check everywhere for an Error,
                  but you would be wise to start off with On Error Goto

                  If none of these work, then backup your App (ideally on a floppy) and
                  start hacking out chunks
                  These problems can be very hard to isolate, you may have to 'emulate'
                  the core AX control to see whether that is what is causing the
                  problem.

                  ..... also it would be wise to do some sort of check to ensure that you
                  do not have mismatched DLLs or OCXes
                  - I'm not sure what the best method of doing that is under XP

                  I expect that AX Control came with a little setup utility, it is
                  possible that it has poisoned your setup.

                  Comment

                  Working...