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. Is it possible to make Visual Studio break whenever a given variable gets a specific value?

Is it possible to make Visual Studio break whenever a given variable gets a specific value?

Scheduled Pinned Locked Moved C / C++ / MFC
csharpvisual-studioquestion
4 Posts 4 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
    Redeemer dk
    wrote on last edited by
    #1

    Hey all. Just wanted to ask if it is possible to make Visual Studio break whenever a given variable gets a specific value? Thanks in advance. -Rune Svendsen

    J C D 3 Replies Last reply
    0
    • R Redeemer dk

      Hey all. Just wanted to ask if it is possible to make Visual Studio break whenever a given variable gets a specific value? Thanks in advance. -Rune Svendsen

      J Offline
      J Offline
      jmkhael
      wrote on last edited by
      #2

      One Word: "Softice" Papa while (TRUE) Papa.WillLove ( Bebe ) ;

      1 Reply Last reply
      0
      • R Redeemer dk

        Hey all. Just wanted to ask if it is possible to make Visual Studio break whenever a given variable gets a specific value? Thanks in advance. -Rune Svendsen

        C Offline
        C Offline
        Chris Meech
        wrote on last edited by
        #3

        Just modify the breakpoint to be a conditional breakpoint. Chris Meech "what makes CP different is the people and sense of community, things people will only discover if they join up and join in." Christian Graus Nov 14, 2002. "Microsoft hasn't ever enforced its patents. Apparently they keep them for defensive reasons only. Or, they could be waiting 'til they have a critical mass of patents, enforce them all at once and win the game of Risk that they're playing with the world." Chris Sells Feb 18, 2003.

        1 Reply Last reply
        0
        • R Redeemer dk

          Hey all. Just wanted to ask if it is possible to make Visual Studio break whenever a given variable gets a specific value? Thanks in advance. -Rune Svendsen

          D Offline
          D Offline
          Douglas Troy
          wrote on last edited by
          #4

          Yes. Set your break-point. Then press the ALT-F9 key to open up the BreakPoints watch window. Select the DATA tab. You'll now have the ability to set an expression based on a value. If you click on the ADVANCE button on that data tab, you can get really fancy. D.

          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