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 find out the line number of died line in VC6.0?

How find out the line number of died line in VC6.0?

Scheduled Pinned Locked Moved C / C++ / MFC
helpquestion
5 Posts 5 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.
  • R Offline
    R Offline
    rambojanggoon
    wrote on last edited by
    #1

    Hi I made some simple program..it sometimes die... so I'd like to know the line number which line cause problem and die. so, is there macro or function to find out died line for VC6.0? Thanks.

    C L 2 3 Replies Last reply
    0
    • R rambojanggoon

      Hi I made some simple program..it sometimes die... so I'd like to know the line number which line cause problem and die. so, is there macro or function to find out died line for VC6.0? Thanks.

      C Offline
      C Offline
      Chandrasekharan P
      wrote on last edited by
      #2

      die?? did you mean crash?? if that is the case then i think you should debug the code and find out where it is crashing

      1 Reply Last reply
      0
      • R rambojanggoon

        Hi I made some simple program..it sometimes die... so I'd like to know the line number which line cause problem and die. so, is there macro or function to find out died line for VC6.0? Thanks.

        L Offline
        L Offline
        lxkjlzz
        wrote on last edited by
        #3

        debug

        T 1 Reply Last reply
        0
        • L lxkjlzz

          debug

          T Offline
          T Offline
          T2102
          wrote on last edited by
          #4

          try __LINE__

          1 Reply Last reply
          0
          • R rambojanggoon

            Hi I made some simple program..it sometimes die... so I'd like to know the line number which line cause problem and die. so, is there macro or function to find out died line for VC6.0? Thanks.

            2 Offline
            2 Offline
            224917
            wrote on last edited by
            #5

            Do you know from which method it is crashing? Does your methods have exception handlers? One lazy way->

            try{
            int nLine = 1;
            //possible crashing code
            nLine = 2;
            //.
            nLine=3;
            //.
            nLine=4;
            //.
            }
            catch(...)
            {
            //log/messagebox nLine
            }

            -Suhredayan

            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