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. Line Number macros to use in output of Message Box?

Line Number macros to use in output of Message Box?

Scheduled Pinned Locked Moved C / C++ / MFC
csharpvisual-studiohelpquestion
2 Posts 2 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.
  • L Offline
    L Offline
    ldsdbomber
    wrote on last edited by
    #1

    I'd like to configure MessageBox(myMsg, myTitle, MB_OK); so that myMsg contains the line number of the source file, I've already made it include the source file name, function and explanation, but it would be useful to be able to have it include the current line number using a macro in Visual Studio ? (I'm on ver 2005) so that as I change the source, the line number is always reported correctly during program execution tks if you can help Lee

    S 1 Reply Last reply
    0
    • L ldsdbomber

      I'd like to configure MessageBox(myMsg, myTitle, MB_OK); so that myMsg contains the line number of the source file, I've already made it include the source file name, function and explanation, but it would be useful to be able to have it include the current line number using a macro in Visual Studio ? (I'm on ver 2005) so that as I change the source, the line number is always reported correctly during program execution tks if you can help Lee

      S Offline
      S Offline
      Stuart Dootson
      wrote on last edited by
      #2

      __LINE__[^]?

      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