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#
  4. Drawing with c#

Drawing with c#

Scheduled Pinned Locked Moved C#
csharphelpgraphicsdata-structuresjson
5 Posts 3 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.
  • K Offline
    K Offline
    kourvoisier
    wrote on last edited by
    #1

    I have a question I dont know if anyone here is familiar with the zedgraph API but its pretty cool. http://zedgraph.sourceforge.net/[^] I am having issues here tho. I want to create a live moving chart that updates in front of your eyes every single second. Stock Market Chart -- candlestick, bar chart, etc. When i start my program i draw the graph but i do not populate it with data yet. I then made a button that when it is pressed it will get the data feed and start populating the graph chart. Here is the problem!!!! When the data comes in my app just freezes!!! (in the background it's just constantly reading in the data not drawing or updated the chart at all) So then i said okay let me just use a small amount of data. When i clicked the button with a small amount of data it did absolutely nothing. But when i minimized my application down to the windows taskbar or toolbar (or whatever its called) and then maximized it (brought it back up and to focus) The chart was populated and everything looked great. I guess my question is why did i have to minimize it and then maximize it to see the results of the drawing of bars on the graph. And why cant i see my data update and draw right in front of my eyes!!! Thanks in advance to anyone who can help me....

    M 1 Reply Last reply
    0
    • K kourvoisier

      I have a question I dont know if anyone here is familiar with the zedgraph API but its pretty cool. http://zedgraph.sourceforge.net/[^] I am having issues here tho. I want to create a live moving chart that updates in front of your eyes every single second. Stock Market Chart -- candlestick, bar chart, etc. When i start my program i draw the graph but i do not populate it with data yet. I then made a button that when it is pressed it will get the data feed and start populating the graph chart. Here is the problem!!!! When the data comes in my app just freezes!!! (in the background it's just constantly reading in the data not drawing or updated the chart at all) So then i said okay let me just use a small amount of data. When i clicked the button with a small amount of data it did absolutely nothing. But when i minimized my application down to the windows taskbar or toolbar (or whatever its called) and then maximized it (brought it back up and to focus) The chart was populated and everything looked great. I guess my question is why did i have to minimize it and then maximize it to see the results of the drawing of bars on the graph. And why cant i see my data update and draw right in front of my eyes!!! Thanks in advance to anyone who can help me....

      M Offline
      M Offline
      M dHatter
      wrote on last edited by
      #2

      How and when are you painting?, show your method. Are you calling your paint method on each pass? Are you double buffering your graphics? Are you looping through your data first, then painting or are you painting on every loop of data?

      T 1 Reply Last reply
      0
      • M M dHatter

        How and when are you painting?, show your method. Are you calling your paint method on each pass? Are you double buffering your graphics? Are you looping through your data first, then painting or are you painting on every loop of data?

        T Offline
        T Offline
        TheJudeDude
        wrote on last edited by
        #3

        I believe you need to refresh your form/chart every time you want to update the chart. You said every second. I would try a timer and the tick event, refresh your form. jude

        K 1 Reply Last reply
        0
        • T TheJudeDude

          I believe you need to refresh your form/chart every time you want to update the chart. You said every second. I would try a timer and the tick event, refresh your form. jude

          K Offline
          K Offline
          kourvoisier
          wrote on last edited by
          #4

          Refreshing the form was exactly what i needed to do. Thanks alot.

          T 1 Reply Last reply
          0
          • K kourvoisier

            Refreshing the form was exactly what i needed to do. Thanks alot.

            T Offline
            T Offline
            TheJudeDude
            wrote on last edited by
            #5

            Happy I could help! Happy Coding! jude

            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